Results 1 to 6 of 6

Thread: BadImageFormatException when opening nDroid Service Settings in Win Server 2012

  1. #1
    Join Date
    Sep 2004
    Location
    Auckland, NZ
    Posts
    5,823

    BadImageFormatException when opening nDroid Service Settings in Win Server 2012

    hi,

    I get this error when opening the nDroid Service Settings in Win Server 2012.

    Code:
    See the end of this message for details on invoking 
    just-in-time (JIT) debugging instead of this dialog box.
    
    ************** Exception Text **************
    System.BadImageFormatException: Could not load file or assembly 'nDroidLib, Version=1.8.4863.1098, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format.
    File name: 'nDroidLib, Version=1.8.4863.1098, Culture=neutral, PublicKeyToken=null'
       at uk.co.beetec.csharp.nDroid.nDroidConfig.XmlSettings..ctor()
       at uk.co.beetec.csharp.nDroid.nDroidConfig.SettingsForm.SettingForm_Load(Object sender, EventArgs e) in C:\Documents and Settings\gbpvr\My Documents\Visual Studio 2008\Projects\nDroidService\nDroidConfig\SettingsForm.cs:line 24
       at System.Windows.Forms.Form.OnLoad(EventArgs e)
       at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
       at System.Windows.Forms.Control.CreateControl()
       at System.Windows.Forms.Control.WmShowWindow(Message& m)
       at System.Windows.Forms.Control.WndProc(Message& m)
       at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
       at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
    
    WRN: Assembly binding logging is turned OFF.
    To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
    Note: There is some performance penalty associated with assembly bind failure logging.
    To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

  2. #2
    Join Date
    Jun 2007
    Location
    Scotland
    Posts
    2,753
    You might be able to get around that problem by manually editing nDroidSettings.xml using notepad. I don't know exactly where it is in Server 2012, but is XP it's C:\Documents and Settings\All Users\Application Data\Beetec Services\nDroid Service

    Alex

  3. #3
    Join Date
    May 2006
    Location
    Canada
    Posts
    28,874
    I think this link has one user's solution to the same error http://forums.nextpvr.com/showthread...ion-of-service

    Martin

  4. #4
    Join Date
    Dec 2004
    Location
    West Yorkshire, UK
    Posts
    4,543
    Quote Originally Posted by reven View Post
    I get this error when opening the nDroid Service Settings in Win Server 2012.
    There's an issue with the settings app on 64-bit versions of Windows that I haven't had a chance to track down yet.

    It's basically just a simple UI for changing the username, password and port. As Alex says, edit the nDroidSettings.xml file using Notepad and you'll be good to go.

    Cheers,
    Brian

  5. #5
    Join Date
    Sep 2004
    Location
    Auckland, NZ
    Posts
    5,823
    cheers found the settings file.


    the issue with 64 bit will be you have it compiled as "Any CPU" but referencing a DLL that only supports 32 bit, so just change "Any CPU" to "x86" and the problem will go away.

  6. #6
    Join Date
    Dec 2004
    Location
    West Yorkshire, UK
    Posts
    4,543
    Quote Originally Posted by reven View Post
    cheers found the settings file.


    the issue with 64 bit will be you have it compiled as "Any CPU" but referencing a DLL that only supports 32 bit, so just change "Any CPU" to "x86" and the problem will go away.
    That's what I originally thought. I'd changed something in the project and somehow the build setting got changed at the same time to "Any CPU" (there are search results on Google of other people having the same issue - they didn't explicitly change the option).

    I've since rebuilt for x86 and posted updated binaries in another thread but it didn't fix the problem. The only 64-bit machine I have to test on is my wife's laptop and every time I think of taking another look at the issue, she's normally using it.

    I'll take some time out to look at it over the weekend.

    Cheers,
    Brian

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •