Exception

Jun 28, 2013 at 4:14 PM
Hi,
Compile in win7 x64, passed (Any CPU), but when run, I get exception immediatly after run:
GlobalHelper.controlHideShow.Enable = false;

Exception:
The type initializer for 'MultiRemoteDesktopClient.GlobalHelper' threw an exception.
System.TypeInitializationException was unhandled
Message=The type initializer for 'MultiRemoteDesktopClient.GlobalHelper' threw an exception.
Source=MultiRemoteDesktopClient
TypeName=MultiRemoteDesktopClient.GlobalHelper
StackTrace:
   at MultiRemoteDesktopClient.RemoteDesktopClient.btnPinServerLists_Click(Object sender, EventArgs e) in C:\Multi RDP Client .NET\multirdpc\RemoteDesktopClient\Forms\Partial Class\RemoteDesktopClient Form\ServerListsEvents.cs:line 209
   at MultiRemoteDesktopClient.RemoteDesktopClient.InitializeControl() in C:\Multi RDP Client .NET\multirdpc\RemoteDesktopClient\Forms\RemoteDesktopClient.cs:line 66
   at MultiRemoteDesktopClient.RemoteDesktopClient.Initialize() in C:\Multi RDP Client .NET\multirdpc\RemoteDesktopClient\Forms\RemoteDesktopClient.cs:line 17
   at MultiRemoteDesktopClient.RemoteDesktopClient..ctor() in C:\Multi RDP Client .NET\multirdpc\RemoteDesktopClient\Forms\RemoteDesktopClient.cs:line 23
   at MultiRemoteDesktopClient.SingleInstanceController.OnCreateMainForm() in C:\Multi RDP Client .NET\multirdpc\RemoteDesktopClient\Program.cs:line 48
   at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.OnRun()
   at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.DoApplicationModel()
   at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.Run(String[] commandLine)
   at MultiRemoteDesktopClient.Program.Main() in C:\Multi RDP Client .NET\multirdpc\RemoteDesktopClient\Program.cs:line 20
   at System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args)
   at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart()
InnerException: System.BadImageFormatException
   Message=Could not load file or assembly 'System.Data.SQLite, Version=1.0.66.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139' or one of its dependencies. An attempt was made to load a program with an incorrect format.
   Source=Database
   FileName=System.Data.SQLite, Version=1.0.66.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139
   FusionLog==== Pre-bind state information ===
LOG: User = JB-PC\JB
LOG: DisplayName = System.Data.SQLite, Version=1.0.66.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139
(Fully-specified)
LOG: Appbase = file:///C:/Multi RDP Client .NET/multirdpc/RemoteDesktopClient/bin/Debug/
LOG: Initial PrivatePath = NULL

Calling assembly : Database, Version=1.0.1122.2011, Culture=neutral, PublicKeyToken=null.

LOG: This bind starts in default load context.
LOG: Using application configuration file: C:\Multi RDP Client .NET\multirdpc\RemoteDesktopClient\bin\Debug\MultiRemoteDesktopClient.vshost.exe.config
LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework64\v2.0.50727\config\machine.config.
LOG: Post-policy reference: System.Data.SQLite, Version=1.0.66.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139
LOG: Attempting download of new URL file:///C:/Multi RDP Client .NET/multirdpc/RemoteDesktopClient/bin/Debug/System.Data.SQLite.DLL.
ERR: Failed to complete setup of assembly (hr = 0x8007000b). Probing terminated.
   StackTrace:
        at Database.Database..ctor()
        at Database.Servers..ctor() in C:\Multi RDP Client .NET\multirdpc\Database\Servers.cs:line 14
        at MultiRemoteDesktopClient.GlobalHelper..cctor() in C:\Multi RDP Client .NET\multirdpc\RemoteDesktopClient\Class Modules\Common Helpers\GlobalHelper.cs:line 49
   InnerException: 

I tried to change config to compile in x86, I get compile error:
Error 2 The type or namespace name 'Crownwood' could not be found (are you missing a using directive or an assembly reference?) C:\Multi RDP Client .NET\multirdpc\RemoteDesktopClient\Forms\PopupMDIContainer.Designer.cs 32 36 MultiRemoteDesktopClient