Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / Web Services / February 2005

Tip: Looking for answers? Try searching our database.

how to used unmanaged class library on a C# web application

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
david chang - 31 Jan 2005 04:17 GMT
Hi, guys

I am trapped into a big trouble on how to use unmanaged class library code in a C# web application.

Now, I am working on a project to develop a web interface for SPlus, a statistical software tool.  By intuitive, I plan to apply C# to develop web side, which will invoke some unmanaged code to use functions of SPlus. I have developed a unmanaged C++ class UM_A to use SPlus functions, and also developed a wrapped managed C ++ class M_A for that unmanaged class UM_A, and used managed M_A in the C# application.

First, I tried those unmanaged and managed classes in a window-based C# application, they are really working, and then, I move them to web application. They are failed. The failure is related to an exception of "FileNotFoundException", suggesting that
File or assembly name M_A, or one of its dependencies was not found.

I am very puzzled. Could you guys tell me what is going on?  I know that C# web application can use Pinvoke c to reuse window DLL, and Marshaling to visit COM. But can it reuse old class library by way of wrapped managed class, and how to do?
I read many articles on how to utilize wrapped managed class for the reuse of unmanaged class library, but all of them are related to windows application.

Thanks

david
Lionel LASKE - 31 Jan 2005 10:08 GMT
Are you sure your legacy DLL (SPlus) is in the system PATH ? Try to copy
this DLL in SYSTEM32.
I've already experiment similar problem with a legacy C++ DLL called from an
ASP.NET application.

                    Lionel.

> Hi, guys
>
[quoted text clipped - 25 lines]
>
> david
OfurGørn - 08 Feb 2005 10:17 GMT
Hi David and Lionel,
I am having a similar problem, I cannot get marshaling to work on my web
service. I am curious, did the PATH solution work for you David, and if so,
how do you do this ?  my dll is under the bin/ directory that .net
autogenerates....
best regards,
Gunnar

> Are you sure your legacy DLL (SPlus) is in the system PATH ? Try to copy
> this DLL in SYSTEM32.
[quoted text clipped - 32 lines]
> >
> > david
Dilip Krishnan - 08 Feb 2005 14:11 GMT
Hello OfurGørn,
   Copying the dll to a system path would make it work

HTH
Regards,
Dilip Krishnan
MCAD, MCSD.net
dkrishnan at geniant dot com
http://www.geniant.com

> Hi David and Lionel,
> I am having a similar problem, I cannot get marshaling to work on my
[quoted text clipped - 54 lines]
>>>
>>> -- Message posted via http://www.dotnetmonster.com

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.