Questions tagged [mono]

1

votes
1

answer
540

Views

Electron-Builder cannot build update for Windows

I am not able to build an update with Electron-Builder and Squirrel for a test application. The problem I think Wine does not find the 7z.exe file. Here's a part of the error that I think is the main problem: Utility: Failed to extract file /Users//developer/electron-examples/installer-and-auto-upda...
asyncerror
1

votes
0

answer
24

Views

Sharing implementation of my interface across .NET subsets

I'm trying to figure out the best way to share a certain class across projects that may refer to different .NET implementations, each having its own subset of libraries. In the days of yore, we used to have the good ol' .NET Framework. Then came Mono, and Xamarin. The latter introduced the concept...
Simone
1

votes
0

answer
120

Views

If/else and while branches in Mono.Cecil

AFAIK, Cecil does not support DefineLabel and MarkLabel. What are the alternatives to use (e.g. generating Nop opcodes) to replace labels when working with if-else and while branches? For example: public void Run(bool someParam) { int someInt = 0; while (someParam) { someInt = someInt + 1; if (someI...
MiP
1

votes
0

answer
36

Views

Checking whether WinForms app is rendered with OS visual styles

We have a legacy WinForms app written at the times of .NET 1.x and may need to change the code that checks whether the app is rendered with the OS visual styles for the reason described below. The current function that does this work looks like this: private bool IsComCtl6 { get { if (!fIsComCtl6Ini...
TecMan
1

votes
1

answer
53

Views

How do I launch doxygen/perl from Monodevelop on linux/flatpak?

I have a mono-based project that is developed on Linux. Is there some trick to getting custom build steps to run in Monodevelop 7 packaged in flatpak? The custom build steps that build the doxygen documentation and package it up do not launch. Doxygen and perl are both installed in /usr/bin, and th...
tekHedd
1

votes
0

answer
67

Views

structured data in c# to byte array and back to structured data in python

This is a long one, please be patient. I am trying to make an AI training loop between Unity3d(C#/Mono) and Python(Neural Network code here). Basically what will happen is that my C# script will send state and environment information of a self driving car equipped with 4 proximity sensors(sensor dat...
WormSandwich
1

votes
0

answer
923

Views

Proper way to create a Mono/Flux from a service that returns a future

How do I properly handle Monos built from futures? I'm trying to get my head around Spring Reactive (and Spring 5), watching all the videos and reading all the blogs I can find, but they all seem to stop short of doing something slightly more than just querying a database, or something else trivial...
Chris Turner
1

votes
0

answer
47

Views

Generate IL using Mono.Cecil for several types

I have several script text files which contain one or more types. These scripts are big files which may contain 10.000 lines each. I parse them and now I want to use Cecil to generate IL. My question is: How can I generate IL for several files and then .Write('myExeFile') I couldn't find how to work...
Rod
1

votes
0

answer
159

Views

System.Windows.Controls in Mono

I am unable to find System.Windows.Controls in Mono. Here's a simple program to reproduce the issue ... using System; using System.Windows; using System.Windows.Controls; public class HelloWorld { static public void Main() { Console.WriteLine ('Hello Mono World'); } } Any ideas/clues/thoughts? Thank...
Naga Vijayapuram
1

votes
0

answer
58

Views

Change the sequence point in PDB file

How can I change the Sequence Point in the PDB file using Mono.Cecil.PDB? Is it possible? My source code is different than the compiled and when I am debugging the positions dont match.
Rod
1

votes
0

answer
118

Views

Loading Assemblies into Seperate AppDomain in Mono Gives FileNotFoundException

I'm working on a sort of plugin system for a Discord bot. Right now i'm on macOS using Mono as my runtime and I've been looking at using seperate AppDomains to load and manage each of the plugins. The plugins themselves do have dependencies but these are already loaded in the main appdomain. So here...
MrMiketheripper
1

votes
2

answer
649

Views

java.lang.NoSuchMethodException: org.springframework.web.server.ServerWebExchange

I want to inject ServerWebExchange exchange in the spring restcontroller like public Mono check(ServerWebExchange exchange) { ... }, but when I run in springboot, an error occurs: java.lang.NoSuchMethodException: org.springframework.web.server.ServerWebExchange.() at java.lang.Class.getConstructor...
kalfen xu
1

votes
1

answer
43

Views

The type `Kaitai.Elf' already contains a definition for `Bits'

I am trying to compile the code from this stackexchange answer: https://reverseengineering.stackexchange.com/a/16631/12521 After adding the System imports and a class definition, I downloaded Elf.cs from http://formats.kaitai.io/elf/csharp.html and tried to compile it mcs -out:unpack.exe Elf.cs unpa...
Zulakis
1

votes
1

answer
124

Views

Error upon variable assignment using GTK# and Mono (C#)

public void OnCombobox1Changed (object sender, EventArgs e) { handler.name = combobox1.ActiveText; } The code sample is a handler (auto generated by gtk# using Mono's gui developer) with my own variable assignment in it. I have three classes, a win class that contains my gui components, which the sa...
SolidDave
1

votes
0

answer
124

Views

Mono Invalid IL code in System.Net.Http.HttpClient:.ctor (System.Net.Http.HttpClient): method body is empty

I am trying to get my C# application to run on Mono. Its purpose is to consume as REST WebApi using System.Net.Http.HttpClient. However, when I run it, the Mono .Net runtime throws the following exception: Unhandled Exception:System.InvalidProgramException: Invalid IL code in System.Net.Http.HttpCli...
CreepyTree
1

votes
0

answer
61

Views

How to specifiy MonoRemoteDebugger application folder?

I'm using MonoRemoteDebugger to develop an app remotely in C#/Mono from Visual Studio 2017 on a Raspberry Pi/Raspbian. I've noticed that the app is placed inside a Temp folder, in MonoRemoteDebuggerServer folder. I was wondering if it's possible to configure MonoRemoteDebugger to place the app in a...
Cristian M
1

votes
1

answer
161

Views

SSL WebRequest in Linux

I'm facing some issues while developing a C# application which sends some data to a remote PHP script in a server through a POST method, using WebRequest. My code is as follows: string url = 'https://myserver.com/myfolder/myscript.php'; string PostDataQuery = 'q=this+is+a+demo'; System.Net.HttpWebRe...
Carles
1

votes
0

answer
1.2k

Views

Mono compiler // Terminal emulator issue

I get this error when I try to compile csharp or fsharp files. This happens when using gnome terminal or jetbrain rider. It works fine in tty or termials like xterm and urxvt. Also I am able to compile c, c++ and go code. Btw, I am using Arch/Antergos and got this issue yesterday. Unhandled Excepti...
Lucas Roschnowski
0

votes
1

answer
889

Views

How to convert System.IO.Stream into a Texture in Unity for Android?

I'm building a client-side Android app in Unity, and when it downloads a jpg from an AWS S3 server, the result comes back as a System.IO.Stream. However my limited knowledge of Mono and .Net means that I'm struggling to figure out how to turn this System.IO.Stream blob of data into a Texture in Unit...
Arthur
1

votes
0

answer
157

Views

Embedding 32bit version of mono when running on 64bit Linux

I'm currently porting a C# plugin from Windows to Linux. On Windows the plugin is loaded using a DllExport nuget package, on Linux I'm looking to use Mono embedding. The program that will use my plugin only has 32bit builds, so I would need to embed the 32bit version of Mono regardless of the OS. On...
TheLast Rar
1

votes
0

answer
80

Views

Facing issue with Binding Library for iOS for magtek and getting errors when build the application after adding reference of this library

I am using magtek device in my application, So, I have made a DLL or Binding Library with the iOS SDK of magtek device, But after making DLL, when I am using this in my application So, my application given error, that are below: /Users/chetu/Desktop/Tusshar/CurrentApp/PsnAmcApp/App12/App12.iOS/clang...
Tusshar
1

votes
0

answer
739

Views

How to debug with MonoDevelop?

I created a regular C# console application in MonoDevelop. I can compile it (if the IDE does not crash) and I can run it in the command line. Now I'd like to debug this console program. How do I do it? MonoDevelop seems not to support that (any more?). I get the error message 'Could not connect to t...
Regis May
1

votes
0

answer
126

Views

Error while compiling monodevelop 7.6 on Archlinux

I'm trying to install monodevelop from package on AUR but no luck. So I tried to compile it from the source code on github. I followed the mono compiling tutorial and installed mono 5.4.1 (a parallel one on /opt/mono, so is other dependencies in the page) and msbuild 15(from AUR) When I enter the en...
Japhsius51
1

votes
0

answer
93

Views

camera serial interface in c# on raspberrypi for windows forms

i have been trying to create a program in c# that takes pictures on regular intervals of time through camera serial interface and saves it in a folder automatically. The problem is how do i enable camera from mono c# and start taking stills at regular intervals of time? Basically a Windows Form that...
user175008
1

votes
0

answer
66

Views

WinForms in Mono - Problems with form repainting

I have a WinForms Application. I need it to run also in Mono. I have a problem with form repainting. There are many controls in the form. When I resize the form or when I try to update it (it needs to be updated on timer tick), the repainting does not work . Sometimes the controls are placed right,...
hinge
1

votes
0

answer
332

Views

Xamarin forms build error in Android project. Could not load assembly…doesn't exist in the Mono for Android profile? Pinvoke.dll

I have been struggling with this error for weeks and have found similar build errors, but not specific to mono.android I am using Microsoft Visual Studio Enterprise 2017 Version 15.6.1 Version 4.7.02556 NuGet Package Manager 4.6.0 Error Exception while loading assemblies: System.IO.FileNotF...
Andrew Cherep
1

votes
0

answer
27

Views

Concurrency in Mono Wcf project

I have a WCF service which uses NetTcpBinding. I need only one thread in my service, so I set InstanceContextMode to Single and ConcurrencyMode to Single. When I run my service on Windows OS, it works how it should be. I wrote a small example to demonstrate this: 03.04.2018 15:56:30: Service started...
skelter
1

votes
0

answer
26

Views

How to add type constants to PDB debug information for a method?

In an AOP templating framework, I would like to have the debugger show concrete items substituting for template items in a method generated from the template. I can show the values of templated string, numeric and enum items by adding them as ConstantDebugInfos to the method's debug information, and...
Anton Tykhyy
1

votes
0

answer
22

Views

Running desktop application c# in mac OSX

I created a desktop application on windows platform on C#. Now, client wants that application to run on MAC OSX. I installed momA and verified my .exe. I also fixed the warnings and errors that mOMA was giving but now I am confused what to do next. I've never port/compile an application for MAC OSX....
Sana
1

votes
0

answer
1.2k

Views

How to compile and run C# project from terminal (Mac OS)

I want to compile and run C# project on Mac OS server. There's no GUI to use, so I need to compile and run it from terminal. I copied the directory of my C# project from my local to the server. (My C# project was created by visual studio for mac.) On the server, I have already installed mono. I ca...
1

votes
0

answer
41

Views

Deterministic builds for Mono 3.2.8

We recently noticed that our C# application has a different checksum on every build, which I've discovered is due to the ECMA 335 Standard for the Common Language Infrastructure. It seems to equate to these values being generated by the compiler: // Time-date stamp: // MVID: Now we have tested buil...
Sixx
1

votes
0

answer
275

Views

Xamarin Forms iOS .Net Standard 2.0 SOAP WSDL - MonoTouch does not support dynamic proxy code generation

I have a Xamarin Forms App. Using latest Xamarin/VS2017 I'm using the built in Connected Service to generate my Proxy from WSDL. It generates a file which I can reference in my .Net Standard project. It compiles/builds fine in all projects. Runs and works fine in UWP. In iOS I receive the following...
aherrick
1

votes
1

answer
121

Views

how to make reference to a GenericInstanceMethod on a GenericInstanceType in mono cecil

The method I want to reference is defined as follow: class Foo { void Bar(int value) {...} } My problem is connected to both Foo and Bar having generic parameters If I use static public GenericInstanceMethod MakeGenericMethod(this MethodReference method, TypeReference[] genericArguments) { var _meth...
Jens
1

votes
0

answer
216

Views

How to use async in ASP.Net MVC for Mono

I am creating an ASP.Net MVC project in Mono using Visual Studio 2017 for Mac. I added the basic controllers, view, models, etc and it's working fine. However, as soon as make the Index method async I am getting the following error: System.InvalidOperationException The view 'Index' or its master was...
MikePR
1

votes
0

answer
115

Views

Cannot use mono profiler - log profiler was not found

I am having a strange problem using mono on linux I have the profiler libraries in my /usr/lib folder: # ls /usr/lib/libmono-profiler-* /usr/lib/libmono-profiler-aot.so /usr/lib/libmono-profiler-iomap.so.0.0.0 /usr/lib/libmono-profiler-aot.so.0 /usr/lib/libmono-profiler-log.so /usr/l...
gtSasha
1

votes
3

answer
227

Views

Can I use an Autorest client in blazor

I am getting a System.PlatformNotSupportedException from the mono platform when trying to run my blazor app on webassembly. I autogenerated a web api client using Autorest. Everything is compiling fine but when I load the code in the browser I get the error below in the browser console. Using a prev...
Nikolaj
1

votes
0

answer
329

Views

dll does not contain valid metadata: compile in Mono

I have a dll file and a script in c#, the two in the same directory. when I try to compile the script I get this message: error CS0009: Metadata file `/home/Lab/Bureau/Csharp/zkemkeeper.dll' does not contain valid metadata Compilation failed: 1 error(s), 1 warnings
Borealis
1

votes
0

answer
25

Views

“JGitInternalException: username is not given” generated from NGit when trying to clone via SSH form Git repository hosted on TFS on-premise

I am using NGit api to connect to git repositories and manipulate them. I have a case where I want to connect to my git repository hosted on TFS on premise. I create ssh key, insert it inside repository everything goes well. But when I want to clone repository I get a message from JGitInternalExcept...
V.Dejan
1

votes
0

answer
427

Views

How to read a running Mono/Unity game process memory using C#?

I'm sorry if this is not the right forum for this question, but I can't really find a better place for it (I tried to ask on reddit some time ago but without success), so here I go. I'm building a game companion app that aims to provide some information to the player about the current state of the g...
Sébastien Tromp
1

votes
1

answer
53

Views

F# interactive Marshal.SizeOf with Mono throws “assertion” error

I am trying to read a GIF file header into a structure with F#, using Mono 5.8 on Mac OSX. The following code sample works fine in Visual Studio 2017 on Windows 10; however, when I try to run it in Visual Studio for Mac, I get the following error in F# interactive: * Assertion at class-accessors.c:1...
bieberman

View additional questions