1
votes

I have just reinstalled GTK# from mono on my windows 10 machine. I have checked my PATH variable and confirmed that C:\Program Files (x86)\GtkSharp\2.12 is referenced. Mono is installed and I am getting the following error in both visual studio and xamarin studio.

Unable to load DLL 'libgtk-3-0.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E)

Here is my application

using System;
using Gtk;

namespace MyNamespace
{
    public static class Program
    {
        public static void Main()
        {
            Application.Init (); // breaks here

            var window = new Window ("Hello from Gtk#");

            window.Resize (200, 200);

            window.ShowAll ();

            Application.Run ();
        }
    }
}

How can I resolve this issue?

1

1 Answers

1
votes

The wrong version of Gtk# was referenced by my project. I deleted all references and added back gtk-sharp 2.12.0 and glib-sharp 2.12.0. The program behaves as expected now.