FAQ Database Discussion Community


Rollback mono 4.0.1 to 3.12.0

linux,ubuntu,mono,rollback,apt
So, our mono was updated from 3.12.0 to 4.0.1 and caused a bunch of problems with nunit as seen here: New SIGABRT after upgrading to Mono 4 running NUnit tests While upgrading to 4.1.0 snapshot fixes these issues, it hasn't been officially released and we would not like to use...

Ubuntu and Ironpython: What paths to add to sys.path AND how to import fcntl module?

python-2.7,ubuntu,mono,ironpython,fcntl
I have latest IronPython version built and running in Ubuntu 14.04 through Mono. Building Ironpython and running with Mono seems trivial but I am not convinced I have proper sys.paths or permissions for Ironpython to import modules, especially modules like fcntl. Running ensurepip runs subprocess, and wants to import "fcntl"....

returning List from Mono DLL c#,linux,list,mono,.net-assembly
I have a project - ASP.NET portal coded/built on Mono/Linux. I have recently moved from using a class from the project for a [nearly] identical version of the class from inside a DLL assembly. Used to get a collection of initialized objects, and now I get nulls. Is this because...

MAC OSX Mono Nuget how to set up a default %AppData%\NuGet\NuGet.config

osx,mono,nuget
I can exec something like - mono --runtime=v4.0.30319 /Library/TeamCity/buildAgent/work/b0d2d3fefe88d393/.nuget/NuGet.exe' install '/Library/TeamCity/buildAgent/work/b0d2d3fefe88d393/something/packages.config' -source 'http://www.someurl.com/feed/' -RequireConsent -solutionDir '/Library/TeamCity/buildAgent/work/b0d2d3fefe88d393/' to tell mono Nuget to look at a specific Nuget Source. But assuming for some reason I could not modify the nuget command line call to add a -source parameter, how could I do...

Merging socket request/response in a function

c#,sockets,mono
I'm trying to implement a client/server application communicating through sockets. The communication works fine and I can match and execute different functions. Most of the packets are from request / response type and are matched with a persistent sequence number. The problem I'm now stating is that I can't lead...

Passing C# enum from C++ using mono

c#,c++,.net,enums,mono
Why can't I get the MonoMethod* for the method that takes an enum, and is there a way to list the methods that mono knows about? Here's a reduced example of what I'm trying to do. I tried different combinations of what (Windows) ildasm reported but no success. // enum.cs...

Ninject.Mvc5 does not work with mono

asp.net,asp.net-mvc,mono,ninject,ninject.web.mvc
Am following video tutorial from you-tube for making web app with ASP.Net. The guy teaching there is using Windows and Visual Studio. I'm on Ubuntu 14.04 and Monodevelop. Everything is set and running but Ninject (3.2.0.0) does not work. After installing from NuGet, it created file NinjectWebCommon.cs have class NinjectWebCommon....

Websocket client disconnect websocket4net

android,websocket,mono,websocket4net
I've been having random websocket disconnects. My stack is: Monodroid Websocket4net Spring websockets I'm not sure if anyone else has experienced this. Usually the client will work perfectly and then randomly, it'll experience a disconnect. Any help or insights would be appreciated....

Using Salt in AES in C# and PHP

c#,php,encryption,mono,aes
I'm trying to encode and decode a string using AES. At the moment, I'm encoding the string in Mono C# using the highest-rated answer here, because System.Security.Crytpography.Aes is not available in Mono. However, this implementation uses a Salt, and the PHP method I'm using to decrypt it does not take...

Can no longer build an old project in Xamarin

c#,.net,build,mono,xamarin
I have an old project that used to build However I have recently tried rebuilding since a xamarin update it and I get an error message The name 'Build' does not exist within the current context. I've tried building it with different versions of the .net framework but none of...

Is safe to call NetworkStream.BeginWrite multiple times from one thread?

c#,unity3d,mono,tcpclient
I am implementing a TCP client in my Unity3D game and I am wondering if it's actually safe or not to call the NetworkStream.BeginWrite without waiting until the previous call finishes writing. From what I understood while reading the documentation, it's safe until I am not performing concurrent BeginWrite calls...

C# How to pool the objects of a node tree efficiently?

c#,reference,mono,dispose,pool
I have a node class that contains only value type properties, and one reference type: it's parent node. When performing tree searches, these nodes are created and destroyed hundreds of thousands of times in a very short time span. public class Node { public Node Parent { get; set; }...

MonoTouch - System.ServiceModel.Dispatcher.ClientOperation fails ("Could not Load signature of [type]).

c#,wcf,mono,monotouch
We have a custom JSON WCF binding that we use in our .net SDK (to support JSON similar to the WebHttpBinding). Our SDK is a PCL supporting .net 4.5, Win8, IOS, Android profile - It works in our Windows Desktop application, and Android without any problem. We are just diving...

How to install Mono version >= 3.10.0 on Ubuntu 14.04 LTS?

ubuntu,mono,ubuntu-14.04
I installed mono with: apt-get install mono-complete but version that come from trusty is is 3.2.8 I follow the installation instructions also form mono-project.com but this result also in version 3.2.8. I am willing to resolve to compile and install from source as a last choice....

Can't compile GStreamer-Sharp on OS X

c#,osx,mono,gstreamer
I'm trying to use Gst# (which is the C# bindings for GStreamer) on Mac, but autotools keeps failing with these last few lines: checking whether to build shared libraries... yes checking whether to build static libraries... yes checking for pkg-config... /opt/local/bin/pkg-config checking pkg-config is at least version 0.9.0... dyld: Library...

How to install Mono mysql connector on ubuntu server

mysql,mono,mysql-connector
I download with wget and unzip.After Go v4.5 and install with gacutil /i MySql.Data.dlland itry compile with gmcs -r:System.dll -r:System.Data.dll -r:MySql.Data.dll Sql.cs And i get this error error CS0006: cannot find metadata file `MySql.Data.dll' Compilation failed: 1 error(s), 0 warnings ...

FragmentManager crashes when using Replace

android,android-fragments,xamarin,mono,monodroid
I have an Activity and few Fragments. I have to replace fragment in FrameLayout. But when I'm using this function my app crashes. Here is the code of function Android.Support.V4.App.Fragment fragment = null; switch (position) { case 0: fragment = new ScheduleFragment(); break; case 1: fragment = new MainFragment(); break;...

“Cannot start Omnisharp because Mono version >=3.10.0 is required”

c#,.net,linux,mono,vscode
I just installed Visual Studio Code and when I started it, it gives me this error. When I try to execute my example application, it gives me TypeLoadExceptions. Cannot start Omnisharp because Mono version >=3.10.0 is required ...

XSocket client with Socket.IO backend?

c#,mono,socket.io,xsockets.net
I was wondering if it's possible to use XSocket as a client and Socket.IO as the server side. I was pretty sure that it wouldn't work but then I read this post, which is effectively the opposite of what I'd like to do. and that seems to work. The major...

Exception thrown by the type initializer for Moq.Proxy.CastleProxyFactory when not running test in isolation

c#,asp.net-mvc-4,mono,moq,typeinitializeexception
Using Moq the following test on a MVC 4 action method that returns a viewmodel with a Stack was created: // GET: /Home/SowingAndHarvesting public ActionResult SowingAndHarvesting() { // Months are used for the CSS classes // to add to the squares and for displayal within the square. var months =...

streamreader's basestream position using mono

c#,linux,mono,streamreader
I am trying to write some simple code to index some wikipedia xml pages. The idea was to get the byte offset of each character by reading in a character using streamreader, then saving the position from the byte stream so I could get back to that position later. using...

NuGet on mono behind proxy not able to connect to the internet

c#,.net,linux,mono,nuget
I have a Linux machine behind a corporate proxy. For the proxy I have setup CNTLM to handle the authentication for me, so my proxy is located at http://localhost:3128. CNTLM connects to a corporate proxy that uses NTLMv2. Now when I try to run Nuget on Mono with the following...

How to differentiate a hyperlink from anything that could execute locally?

.net,windows,security,hyperlink,mono
Scenario: An app that supports hyperlinks inside content. The app has code to execute the hyperlink that looks like this: Process.Start(href); // href is the link, e.g. "http://www.google.com" Question: The user can set arbitrary content in the string, and the app needs to sanitize it and disallow non-URLs such as...

Blank white screen on error with Kestrel ASP.NET 5

mono,asp.net-5
I'm trying to develop an asp.net 5 website using Mono and Kestrel development server. When the website compiles properly, I'm able to load the website without any dramas on the local development port after launching k kestrel However, if there is an error with my .cshtml view file (referencing wrong...

bash error code 137 vs 1 when out of memory

c#,bash,mono
Context I run the following command in linux bash : mono --debug --debugger-agent=transport=dt_socket,address=198.178.155.198:10000 ./Stress.exe Stress.exe is a C# application. What happens At one point the system is out of memory, which is wanted. An error code is returned. Error code returned (echo $?) Code 1 : When my program creates...

Open existing window in Gtk#

c#,.net,mono,gtk,gtk#
I have added a new window to the project and the name of the window is Actwindow. How can I open this window? I tried using Actwindow=new Window(); but it does not work. The window code is: using System; namespace myproject { public partial class Actwindow : Gtk.Window { public...

MVC 5 on Raspberry Pi using Mono

mono,asp.net-mvc-5,raspberry-pi
I'm trying to get an MVC 5 project running on my raspberry pi, following a guide for MVC 3. (here) I've been trying for hours straight to no avail.. I am wondering if anyone has got this going in any way, because I tried with lighttpd and nginx, but both...

How can I install MONO on Centos 5, without compiling from source

linux,mono,install,centos5
I would like to install a reasonably recent version of Mono on a CentOs 5 system. Ideally I would prefer not to have to build from source. I set up a mono.repo file in yum.repos.d: [mono] name=Mono Stack (RHEL_5) type=rpm-md baseurl=http://download.mono-project.com/repo/centos/ gpgcheck=1 gpgkey=http://download.mono-project.com/repo/centos/repodata/repomd.xml.asc enabled=1 When I tried to use the...

How to run functions on main thread without using Coroutine in Unity

c#,multithreading,unity3d,mono
I've come across some articles about using coroutine to run functions on main thread, such as Thread Ninja: IEnumerator StartExamples() { //Jump to main thread yield return Ninja.JumpToUnity; Destroy(someGameObject); //OK //Jump back to background thread yield return Ninja.JumpBack; } It didn't work on my code since I wanted to jump...

Xml serialization fails with NullReferenceException on simple class

c#,unity3d,mono
I've got the simple class I want to serialize: public class InnerCharacter : Object { public double xp; public double hp; } I tired difference approaches, for example: public static void TestSerialize() { InnerCharacter c = new InnerCharacter(); Serialize(c); } static public void Serialize(InnerCharacter details) { XmlSerializer serializer = new...

System.Data.SqlClient.SqlConnection “Exception: Unknown packet type 74”

c#,mysql,mono,sqlconnection
I’m attempting to connect to a MySQL database using System.Data.SqlClient.SqlConnection and I’m getting an “Exception: Unknown packet type 74”. This is technically through Unity3D 4, although I’m not sure that’s relevant to the problem.* It seems to be a C# issue, and not a mono issue - even though the...

Using mono to call C# from C/C++

c++,.net,linux,mono
I need to write docx files on Linux so I'm compiling the Open-XML-SDK with mono. I'm trying to do what this website suggests. What can I do to understand why I can't get the MonoMethod* object for the constructor, or better, get this to work? Here are my sample programs...

Why am I getting the following error when compiling this assembly?

c#,unity3d,mono,.net-assembly
I'm attempting to use the following command line command to compile an assembly of the code from my project: C:/"Program Files"/Unity/Editor/Data/Mono/bin/gmcs -target:library -out:C:/Users/Austin/Desktop/PixelExpanse.dll -recurse:C:/Users/Austin/Desktop/Projects/Repos/trunk/PixelExpanse/SpaceColonyRefactor/Assets/Source/*.cs -d:RUNTIME -r:C:/"Program Files"/Unity/Editor/Data/Managed/UnityEngine.dll As you can see, I am, I believe, correctly referencing the UnityEngine.dll. The code that would be compiled contains references to UnityEngine.UI...

Mono kestrel duplicate enviroment variable

c#,ubuntu,mono,asp.net-5
I get the following error when I run k kestrel: System.ArgumentException: An element with the same key already exists in the dictionary. at System.Collections.Generic.Dictionary`2[TKey,TValue].Add (System.Collections.Generic.TKey key, System.Collections.Generic.TValue value) [0x00000] in <filename unknown>:0 at System.Linq.Enumerable.ToDictionary[DictionaryEntry,String,String] (IEnumerable`1 source, System.Func`2 keySelector, System.Func`2 elementSelector, IEqualityComparer`1 comparer) [0x00000] in <filename unknown>:0 at...

Cannot start OpenDebug because Mono (or a Mono version >= 3.10.0) is required

mono,vscode
I have downloaded and install vscode in ubuntu 14.0 lts, and include existing node.js project. First think I have to do with vscode is debugging my app, for that I have go to debug (ctrl+shift+D) penal, configure launch.json file with "name" and "program"="app.js" properties. Put debug point in app.js file...

Using VSCode: How to debug a mono process which is started from another mono process

c#,debugging,mono,vscode
I have a process 'a.exe' which I can debug it without any problem. mono --debug --debugger-agent=transport=dt_socket,server=y,address=127.0.0.1:55555 a.exe The problem occurs when I want to debug a new process ('b.exe') started by 'a.exe' instead of 'a.exe' itself. Here is the code. var startUpInfo = new ProcessStartInfo('b.exe', argumentsOfB); Process.Start(startUpInfo); I have to...

Making GTK# Window non resizable

c#,mono,gtk,gtk#
I have a GTK# Window i need to prevent user from resizing it.seen this answer How to set a fixed windows size in GTK and C but i cannot find the correponding method for gtk_window_set_resizable (GTK_WINDOW(mainWindow), FALSE); for C# here http://docs.go-mono.com/?link=T%3aGtk.Window

FormsAuthentication of ASP.NET app running on Mono

apache,asp.net-mvc-4,ubuntu,mono,xsp
I have an ASP.NET MVC4 web application which was developed using Visual Studio in Windows. I am trying to deploy it to an Apache server running on Ubuntu. I am settling for getting it working on xsp for time being, since that seems simpler to start. The latest in a...

convert JSON string to array mono

c#,json,mono
I'm trying to convert a string with JSON data to an array. I'm using NewtonSoft.JSON The following line of code holds my JSON data in a string: string jsonString = manage.getData(); I've tried the following: name[] result = JsonConvert.DeserializeObject<name[]>(jsonString); string name = result.Name; Name class: using System; namespace Zoekfunctie {...

Alternative to multi-binding and converters?

c#,.net,xamarin,mono,monodroid
I'm looking for an alternative for two reasons: Multi-binding and converters are not available for Xamarin.Android (correct me if I'm wrong). Binding requires atleast one side to be a dependency property (which sucks). I'll try to explain what I want through code: Given classes Foo and Bar: class Foo {...

ASP.NET on Mac OSX Build Failed (are you missing an assembly reference?)

c#,asp.net,osx,mono
Ok people, I'm working on some project for school which should be done with ASP.NET, but I have a mac. So I did a research on how to run asp.net web app and followed this tutorial https://www.youtube.com/watch?v=1g2I9SJZ5XI In between I runned on to some error with mono https://github.com/aspnet/Home/issues/498 Managed to...

WebRequest not working with ssl on Xamarin.Forms, despite servicePointManager hack

mono,monotouch,xamarin,monodroid,xamarin.forms
I am writing an application that needs to read from a REST api that is only available over https. I am running into the issue where the request fails in Mono.Security, with the message: "The authentication or decryption has failed." I did my research and found that Mono by default...

using mono to host a asp.net owin webpage on the pi results in bad host

c#,asp.net,mono,raspberry-pi,owin
While i was trying to port a owin asp.net website to the pi, (raspberry pi model b) I ended up with a website displaying the error page : Bad Request (Invalid host) On the pi i am running raspbian wheezy. I installed mono (version 3.2.8). For a simple console aplication...

C# Unity Engine destroy() subclass

c#,unity3d,mono
Hello i have this code: public abstract class Test : MonoBehaviour { public abstract void OnStart(); public abstract void OnUpdate(); private void Start() { OnStart(); } private void Update() { if (Input.GetKeyDown(KeyCode.X)) { Destroy(this); } OnUpdate() } } then I have the this: public class SecondTest : Test { public...

why is gmcs command in bash(mono) missing the namespace `System.Threading'?

mono,gmcs
I input this command gmcs -t:library Program.cs and get this error Program.cs(6,14): error CS0234: The type or namespace name `Tasks' does not exist in the namespace `System.Threading'. Are you missing an assembly reference? I get I have to give it the paths and everything, but how? can't find the way...

how to eliminate dependencies with mcs (mono) command in bash?

c#,bash,mono
I use the following command for mono in bash (to compile a C# program) mcs -t:library -r:nunit.framework.dll *.cs it works and I have my Program.dll. However, when I try to use the dll (with NUnit for example) if I don't have the nunit.framework.dll in the same folder, it doesn't work....

mono make install fails with “Error 1”

mono,make
I've finally managed to get mono to build from sources, but make install invoked from the top build directory fails at the following point: make[6]: Entering directory `/bld/mono/mono-4.0.0/mcs/class/System' make install-local WARNING: generic atexit() called from legacy shared library make[7]: Entering directory `/bld/mono/mono-4.0.0/mcs/class/System' MONO_PATH="./../../class/lib/build:$MONO_PATH" /bld/mono/mono-4.0.0/runtime/mono-wrapper ./../../class/lib/build/gacutil.exe /i ./../../class/lib/net_4_5/System.dll /f /root /usr/mono/lib...

Fail to build Mono.Addins with the latest Mono 4.3.0 and GTK# on Ubuntu 14.04

ubuntu,mono
Trying to build the latest Monodevelop with latest Mono. I have successfully installed Mono 4.3.0 and GTK#. As I can see, Monodevelop needs Mono.Addins installed, but when I trying to install latest Mono.Addins, it fails with next errors: Mono.Addins.Gui/AddinManagerDialog.cs(189,24): error CS0506: `Mono.Addins.Gui.AddinManagerDialog.Dispose()': cannot override inherited member `GLib.Object.Dispose()' because it is...

xbuild - where is the compiled app?

mono,xbuild
I have just started using xbuild to compile my C# solutions using Visual Stuido's .sln files. The outcome is two folders: bin and obj placed in the same localization as the .cs files of the project. Both of them contain folders for Debug and Release versions, and both those versions...

log4net cross platform XML config

c#,.net,linux,mono,log4net
I have a requirement to store my log files in a Logs sub folder. Normally you would do this my modifying the FileAppender in you App.config as follows: <file type="log4net.Util.PatternString" value="Logs\MyLog.log" /> However this is not cross platform because if you run this on linux it will create a file...

SignalR and Websockets on Mono

c#,.net,mono,.net-4.5,owin
I've done hours of scouring, trying to figure out why the websockets transport doesn't work through signalr on my c# 4.5 application running on linux via mono 4.0.1. References in my project: Microsoft.Owin.Host.HttpListener Microsoft.Owin.Host.SystemWeb Right now, I'm trying to figure out where the bottleneck is that is preventing websockets from...

Import LibGaze dll file in Unity3D

c#,dll,unity3d,mono
I want to import the dll file of LibGaze in Unity. I put the dll in the "Assets/Plugins" folder. I managed to add that dll as reference in mono editor, the namespace and classes seem to be recognized by mono editor without problem (when I type class names in the...

Warning: Degraded allocation. Consider increasing nursery-size if the warning persists

c#,android,mono,xamarin
I have suddenly the error in the subject but have no idea how to set this in VS2012. Found this answer but dont get it exact how to adjust it: Degraded allocation. Consider increasing nursery-size if the warning persists This is my complete error code: GC_OLD_BRIDGE num-objects 0 num_hash_entries 0...

Where can I find the definitions of System.Collections.Concurrent classes in the mono source code?

c#,collections,mono
I am looking for the source code of the System.Collections.Concurrent classes, especially ConcurrentQueue and ConcurrentDictionary in the mono sources. I am unable to find them. I was looking in the corlib Directory: https://github.com/mono/mono/tree/master/mcs/class/corlib but it does not contain the System.Collections.Concurrent package. Even using the repository search feature of github did...

Pass array to C# from C++ via mono

c#,c++,.net,linux,mono
I need to pass an array from C++ to C# using mono. But I can't get mono_array_set() to compile. So how can I pass an array from C++ to C#? I've tried mono_runtime_invoke() which compiles but gives a runtime error. mcs /nologo /warn:4 /debug:pdbonly /o /nowarn:3003 /platform:x64 /out:array.dll /target:library array.cs...

Run -> Exception not available in in Mono Develop 5.7

mono,monodevelop
In Mono Develop 3.X, there is a menu option to configure exceptions we wish to break on (Run -> Exceptions). But with Mono Develop 5.7 IDE it is no longer there? Also Debugger is not breaking on exceptions. Any idea How to get it back, probably some add-ins ?...

Action bar app icon missing with Android 5 in Mono.android

android,mono,icons
How to Implement Action bar app icon missing with Android 5 in mono.android and I have already used this link Action bar app icon missing with Android 5 but its not working....

Mono on OSX, Process.Start sometimes throws native wrapper exception that is unhandleable

c#,multithreading,osx,mono,process.start
So I have a console application running in Mono 3.12.0 on OSX. Occassionally, and I mean, maybe once every 100 or more executions of CleanupPriorToApplicationStart(), I get the stacktrace below and the parent thread that calls the cleanup method dies; basically Process.Start must wrap native code and that native code...

How do C# threads cause memory leaks when they already finished?

c#,multithreading,memory-leaks,mono,xamarin
Here's my code: using System; using System.Collections.Generic; using System.Threading; namespace testt { class MainClass { public static List<TestObject> testjobs = new List<TestObject> (); public static void Main (string[] args) { Console.WriteLine ("Hello World!"); addTask (); //put a breakpoint here Thread.Sleep (5000); deleteObj (); while (true) { Console.WriteLine ("MAIN STILL EXISTS!");...

Building Mono Without Bash: Syntax Error in doltlibtool

bash,shell,build,mono
I'm building mono on an android device and getting an error when the build runs ./doltlibtool make[4]: Entering directory `/bld/mono/mono-4.0.0/eglib/src' CC libeglib_la-garray.lo ../doltlibtool: line 4: syntax error: unexpected "(" Here is line 4 of doltlibtool: 1 #!/bin/bash 2 top_builddir_slash="${0%%doltlibtool}" 3 : ${top_builddir_slash:=./} 4 args=() 5 modeok=false 6 tagok=false From what...

vscode: how to setup debugging mono/c#?

c#,mono,vscode
I'm trying to setup Visual Studio Code (https://code.visualstudio.com/docs/debugging ) to debug c#/mono on win8. I have also installed the latest version of mono. I added a config to launch.json and changed the 'type' to mono(also tried pointing 'program' at the debug exe) but I just get the error: initialize: can't...

Newtonsoft JSON.NET 6.0.8 and Mono on Mac OSX fails in glorious manner

c#,mono,json.net
I've built a distributed systems application that makes heavy use of JSON. The app runs great natively on Windows (tested on 7, 8, 8.1, Server 2008, Server 2012) and Ubuntu 14.04 with Mono However, the app fails in a glorious manner when I attempt to run it on OSX Yosemite...

ASP.NET on Mono 4.0 - Objects Not Found

c#,asp.net,.net,mono,monodevelop
I am fairly new to ASP.NET and am having issues getting the IDs for ASP objects in the *.aspx files to be detected by the C# files inheriting the page (the associated *.aspx.cs files). For some context, I have been tasked with migrating an ASP.NET website from an IIS Server...

Switch to a program on Linux Debian

c#,linux,mono,debian,crontab
I have developed a program in C# using mono toolkit. The program works like a charm on my Linux Debian VPS. I need this program to run constantly and I execute it via a crontab. The process is effectively running in the background. However, I am not able to "show"...

Values GridView in cells

c#,asp.net,gridview,mono
I am trying to get values of string that I keep inside GridView. When I use regular BoundFields, things work get. I get whatever is needed with: string my_value = myGrid.Rows [rowIndex].Cells[1].Text; However, one grid needs to have hyperlinked entries in one of the columns. I did: <asp:BoundField DataField="domainName" HeaderText="Domain"...

Compiling C# projects with VSCode on Ubuntu

c#,ubuntu,mono,vscode
I set up VSCode on Ubuntu 14.04 according to the various tutorials available in the documentation - I tried as many as I could make sense of. The editor runs without issue and (after working through Mono version discrepancies) provides a superior coding experience as compared to most of the...

F# task parallelism under mono doesn't “appear” to execute in parallel

asynchronous,f#,mono,task-parallel-library
I have the following dummy code to test out TPL in F#. (Mono 4.5, xmarin studio, quard core macbook pri) To my surprise, all the processes are done on the same thread. there is not parallelism at all. open System open System.Threading open System.Threading.Tasks let doWork (num:int) (taskId:int) : unit...

Error in build from Dockerfile for Ubuntu image with Mono installed

xamarin,mono,docker,ubuntu-14.04,boot2docker
I have the following docker file that I am attempting to use to build a Ubuntu image with mono. FROM ubuntu:14.04 MAINTAINER John Smith <[email protected]> RUN sudo apt-get update RUN sudo /bin/bash -l -c apt-get install wget RUN sudo /bin/bash -l -c apt-get http://download.mono-project.com/repo/xamarin.gpg RUN sudo apt-key add xamarin.gpg RUN...

How to install Mono 4.0.1 on Debian 8?

linux,mono,debian
I am attempting to install Mono-Complete onto a fresh brand new installation of Debian 8 in order to use ASP.NET 5 as per (code.visualstudio.com/docs), have followed the mono-project.com documentation for Ubuntu 12.04/Debian 8 or later with regards to the second repository that is needed. However, after following the instructions and...

DependencyResolutionException Circular component dependency detected: How to use Autofac to inject decorator?

c#,dependency-injection,mono,decorator,autofac
I have an interface called ILastActivityUpdator as follows: public interface ILastActivityUpdator { void UpdateLastActivity(int userId); } Besides that I have two classes that implement this interface, being LastActivityUpdator and a decorator AnonymousUserLastActivityUpdator. The latter one takes an ICookieProvider as extra argument and uses this in the method implementation. I.e., public...

XML validation with XSD fails while online validators pass

c#,xml,mono,xsd-validation
I have a simple XML file that I want to validate against an XSD. However, whenever I run my validation code, I get a validation exception saying the "multitest" node is undefined (unlocalized error message: "The multitest element is not declared."). The strange thing is that I tried to validate...

Mono cannot find dll that seems to exist

vb.net,ubuntu,mono
I have just upgraded my 64-bit ubuntu 14.04.2 LTS to the latest mono. I followed the instructions on this page a few months ago, and before today had been using mono 3 without issue. Today I upgraded, which moved me to mono 4.0.1: $ mono --version Mono JIT compiler version...

Using DirectoryInfo to access a network drive

c#,mono,raspberry-pi
I'm creating an application on the Raspberry Pi with c# and mono. When it uses DirectoryInfo and sets it to the network path it adds home/pi/ in front of the path. How can I prevent this? DirectoryInfo di = new DirectoryInfo(@"//192.168.1.13/Volume_2/Folder"); Console.Write("File: " + di.FullName+ ": "); Console.WriteLine(di.Exists); ...

Is .NET Execution Environment (DNX) similar to mono?

.net,mono,dnx
Here is the description of DNX: The .NET Execution Environment (DNX) is a software development kit (SDK) and runtime environment that has everything you need to build and run .NET applications for Windows, Mac and Linux. It provide a host process, CLR hosting logic and managed entry point discovery. DNX...

How to tell what DLL's a Mono/Gtk# app depends on (Windows)

c#,windows,mono,gtk#
I have a simple gtk# mono app running on windows. It works fine on my PC which has Mono, .NET, and GTK installed. But if I give the exe to a friend it obviously doesn't work. Mono's mkbundle tool doesn't seem to work on windows without an enormous amount of...

How to use ServiceStack with Razor on mono

ubuntu,mono,servicestack
I've been following the rockstars razor demo code from ServiceStack and I run into an issue when attempting to run on mono. Self host - runtime views (Razor based pages hang - basic html returned fine) Self host - compiled views - has issues with RazorGeneratorBuildTask on mono build server....

How to disable automatic Nuget Package Update in Xamarin

xamarin,mono,nuget
How to disable automatic Nuget Package updates in Xamarin 5.9 (build 539) when opening a new Project?

Mono C# compiler response file syntax

c#,.net,mono
I have a basic foundation in C#, having used it briefly at a previous job. Right now I'm working on really understanding the language and its paradigms by going through Pro C# 5.0 and the .NET 4.5 Framework. However, my main computing environment is a GNU/Linux system so I'm doing...

CultureName of System assembly in .NET

c#,.net,mono
While writing some code handling assemblies in C# I noticed inconsistencies in field values of Assembly object (example of System assembly): > typeof(string).Assembly.FullName "mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" but when accessing CultureName field of AssemblyName object directly, its value is an empty string: > typeof(string).Assembly.GetName().CultureName "" When I run the same...

Preview an ASP.NET .CSHTML file in XSP

asp.net,mono,asp.net-webpages,xsp
Is there a way to force XSP on Mono to parse .cshtml files in order to be able to only preview them before doing the routing? Could the setting be forced? Currently, the server only forwards the file for download and does not process it. Running latest stable version of...

Running on iOS 7.1 simulator brings errors in the console output

ios,xcode,xamarin,mono,monotouch
I'm using Xamarin Studio 5.9.3 on Mac with Mono 4.0.1, Xcode 6.3.2 and Xamarin.iOS 8.10.1.64. When I try to run my app in the iOS 7.1 simulator I get the following console output: objc[1102]: Class AXEmojiUtilities is implemented in both /Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 7.1.simruntime/Contents/Resources/RuntimeRoot/System/Library/PrivateFrameworks/AccessibilityUtilities.framework/AccessibilityUtilities and /Library/Developer/CoreSimulator/Profiles/Runtimes/iOS...

Raycast2D not working with LayerMask

c#,unity3d,mono
I am attempting to use a Raycast2D to detect if an attack has hit an enemy. I created a LayerMask for the "Enemy" layer and I have an object with a collider on the "Enemy" layer. I have no problem hitting the collider without using a LayerMask, however when I...

How to capture mouse events in C# MonoMac

c#,xamarin,mono,nswindow,monomac
First off all, my goal is to create pragmatically (no controllers or such things, just single class) borderless NSWindow. In this window I'd like to track mouse events, like: Mouse down, mouse move. As simple as that. I need to do this in C# using Xamarin Studio in Monomac project....

Running NUnit tests on Mono on Windows

c#,windows,unit-testing,mono,nunit
I am new to Mono and I would like to be able to run tests on Mono. I created as simple unit test project in Visual Studio 2012 and compiled it against .NET 4.5. using NUnit.Framework; namespace ClassLibrary2.Tests { [TestFixture] public class Class1Tests { [Test] public void MyTest() { var...

Xamarin build cross platform sdk for native developers

android,ios,mono,monotouch,xamarin
I'm going to build a sdk target for android & ios developers. I thought maybe instead of writing it for objective c and java i will use mono cross platform to my advance. The only issue is that xamarin can generate apk and ipa. Is it possible to make it...

Xamarin Forms: How can I add padding to a button?

xaml,xamarin,mono,monotouch,xamarin.forms
I have the following XAML Xamarin.Forms.Button <Button Text="Cancel" BackgroundColor="#3079a8" TextColor="White" /> I tried to add padding to it via the Padding property but that didn't work. After checking the forums and the docs, I realised there is no padding property in the documentation for Xamarin.Forms.Button (link to the docs) ,...

Monodevelop: “MSBuild process could not be started”

mono,monodevelop,mdtool
I just installed monodevelop on Arch Linux using pacman. I can compile with the mcs command, but I can not build in monodevelop. I am told "MSBuild process could not be started". The same error is given if I try building with mdtool on the command line.

Namespace could not found on Mono

c#,mono
I want to create a cross platform application. For that, I am using Mono. When I compile my code in Mono, I get an error: vehicleRouteCorePlanner (my dll file) could not found. But I have added that dll into my project. error in line 2 and 3 It is running...

get Subject Key Identifier of certificate with openssl commands [closed]

linux,mono,openssl,certificate
i want to get get Subject Key Identifier of my certificate using openssl and also every x509 extensions property of my certificate but i didn't find any solution. please help if there is a way to do it. I need the OpenSSL commands to do it....

Mono on Linux and Missing methods exception

c#,.net,linux,mono
Been trying to program a GTK# app with mono that works on Linux (though GTK# is not directly related to my question). Now, the problem I've run into is that I'm using the function MapToIPv4() in IPaddress. When targeting Mono 4.5 this function works just fine but when rolling it...

Via rotate orientation change layout without reload OnCreate()

android,xamarin,mono,orientation
I have 3 Layouts in different folders : 1.layout/HomeLayout.axml (where layout is an folder for layouts and HomeLayout.axml is an global axml file). 2.layout-large-port/HomeLayout.amxl (where layout-large-port is an folder for large(dimension of display) portrait and HomeLayout.axml is axml file). 3.layout-large-land/HomeLayout.axml(where is layout-large-land is an folder for large(dimension of display) landscape...

IL2CPP Compiler Runtime Errors for Unity3D iOS 64-bit

c#,ios,unity3d,mono,chess
I have a Unity3D Mobile Chess app I am porting from 32-bit to 64-bit with Unity 3D 4.6.5f1. It's using OpenGLS2.0, .NET 2.0 libraries, and Universal binaries are being generated. I am getting a runtime error which in the debugger says the following: NullReferenceException: A null value was found where...

nameof with Generics

c#,generics,mono,c#-6.0
I was experimenting with nameof with generics. I didn't get the result I was expecting. I'm not sure if this is part of the spec or not. class MainClass { public static void Main (string[] args) { Console.WriteLine ($"Hello { nameof(FooBar<string>)! }"); } } class FooBar<T> { } The output...

Can't send parameters through POST on asp.net vNext app. (beta 3) (MV6, mono, EF7, OSX)

asp.net,osx,post,mono,asp.net-mvc-6
I hope someone can help me with this... I'm working on osx on a new small project and "getting to know" the new vNext with MV6 and Entity Framework 7, with mono, kestrel, and using sublime text for the coding... I have a very simple form: <div class="login-form-outer"> @using (Html.BeginForm("Login2",...

How to use hyper linking in Razor without Url.Action or Html.Action

c#,asp.net-mvc,url,razor,mono
There are 4 ways to hyperly link views in ASP.NET MVC as far as I know: @Url.Action @Url.ActionLink @Html.Action @Html.ActionLink I can use them as, for example: <a [email protected]("ActionName","ControllerName")> Test </a> Which generates: <a href="ControllerName/ActionName"> Test </a> Is there a way to generate the Url part i.e. "ControllerName/ActionName" in ASP.NET...

ViewData inside of ViewData string

c#,mono
I am loading a table dynamically, and there is an unknown number of rows. Each row (each cell, actually) is loaded from the database and concatenated into a string: tableItems+="<td colspan='8' class='reportHeaderMain borderThin'> @ViewData[\"" + tString + "Title\"]</td>"; in the code above, tString is the item number, so the title...

Mono ASP.NET MVC tilde in href causes System.NotImplementedException

asp.net,asp.net-mvc,mono
I am trying to make an ASP.NET app using Mono 3.12.0 on Ubuntu 14.04.1. Whenever I try to use tildes in the hrefs in my _Layout.cshtml, I get a System.NotImplementedException. I have made 3 different ASP.NET MVC Razor solutions with MonoDevelop and each one has the same problem. My _Layout.cshtml...

how to solve the type and namespace could not be found

c#,namespaces,mono
I am trying to make a cross platform application using MONO. i developed the project into c#(windows) and I want to run that project into Linux. For that purpose i am using MONO.But when i am running my project then I am getting error that the type and namespace could...

What is changed about reflection in mono 4.x? (compatibility with mono 3.x)

c#,.net,mono
My exception with mono 4: Unhandled Exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.InvalidProgramException: Invalid IL code in (wrapper delegate-invoke) <Module>:invoke_callvirt_CancellationTokenRegistration_CancellationToken&_Action`1<object>_object (System.Threading.CancellationToken&,System.Action`1<object>,object): IL_0057: castclass 0x00000007 more details available here: https://github.com/Anthilla/Antd/issues/8...

WindowsAzure.Storage using C# mono

c#,azure,sdk,mono
Im trying to connect and download from AzureStorage blob which I manage to do using windows while writing in C#. While working on linux however Im missing : Microsoft.WindowsAzure.Storage; I've been adviced to use https://github.com/richorama/azure-sdk-for-mono but I cant get it to compile If anyone have managed to do this all...