[.NET]TypeLoadException

The engine

[.NET]TypeLoadException

Postby klkim » Fri May 02, 2008 3:39 pm

Hi, all

Using SMILE.NET, after importing smilenet.dll in Visual Studio 2005 reference, build is OK.

But when I run a code, there is TypeLoadException in this line "Smile.Network net = new Smile.Network();".

Is it necessary to use P/Invoke technology or [DllImport ...]?

Thank you in advance.

Best Regards,
klkim
klkim
 
Posts: 6
Joined: Fri May 02, 2008 3:28 pm

Postby klkim » Fri May 02, 2008 4:12 pm

If the cause of above problem is based on different compiler (because I am using visual studio 2005, but I think the smilenet.dll is made on visual studio 2003 right??), the only solution is to rebuild smilenet.dll in my development environment?
klkim
 
Posts: 6
Joined: Fri May 02, 2008 3:28 pm

Postby shooltz » Fri May 02, 2008 8:54 pm

I can create console or WinForms app in VS 2005, add the reference to Smile.NET (the public binaries, compiled with VS 2003 and available on our download page) and run the program which creates Smile.Network object and calls its methods.

What's the type of your project? Is it a webforms app?
shooltz
Site Admin
 
Posts: 829
Joined: Mon Nov 26, 2007 5:51 pm

Postby klkim » Sat May 03, 2008 10:38 am

The type of my project is Windows Application Program in VS2005 project template.
klkim
 
Posts: 6
Joined: Fri May 02, 2008 3:28 pm

Postby shooltz » Sat May 03, 2008 10:57 am

klkim wrote:The type of my project is Windows Application Program in VS2005 project template.


Can you zip the sources of your project and post it here, so I can try to reproduce the problem?
shooltz
Site Admin
 
Posts: 829
Joined: Mon Nov 26, 2007 5:51 pm

Postby klkim » Sat May 03, 2008 12:43 pm

I have confused the namespace of the project. :(
Now, I solved the exception problem.

Thank you very much, shooltz.
klkim
 
Posts: 6
Joined: Fri May 02, 2008 3:28 pm


Return to SMILE

Who is online

Users browsing this forum: No registered users and 2 guests

cron