Yes, if you need to export functions from the DLL, that's pretty much the
only option. Setting it up takes a bit of fiddling around, but it's fairly
simple afterwards.

> -----Original Message-----
> From: Discussion of advanced .NET topics.
> [mailto:[EMAIL PROTECTED] On Behalf Of James Berry
> Sent: Thursday, January 03, 2008 07:52
> To: ADVANCED-DOTNET@DISCUSS.DEVELOP.COM
> Subject: Re: [ADVANCED-DOTNET] Creating unmanaged DLL from .net
>
> So the suggestion is to use managed C++ to write a unmanaged
> .DLL wrapper which calls into the appropriate .net managed assemblies?
>
> Best wishes
> James
>
>
> -----Original Message-----
> From: Discussion of advanced .NET topics.
> [mailto:[EMAIL PROTECTED] On Behalf Of
> Gyorgy Bozoki
> Sent: 03 January 2008 13:30
> To: ADVANCED-DOTNET@DISCUSS.DEVELOP.COM
> Subject: Re: [ADVANCED-DOTNET] Creating unmanaged DLL from .net
>
> If you can use ComVisible = true, that's a relatively easy
> option - you can use any .Net language for that. If COM is
> not an option, you'll have to use
> C++: in your project you'll have to turn on managed code
> generation for
> specific C++ files. You cannot have precompiled headers in
> the project (you can still use stdafx.h, but precompiled
> headers must be off.)
>
> Other than the above, the rest is fairly straightforward with
> VS 2005. Look into #pragma managed, gcnew and the handle operator (^).
>
> HTH,
> Gyorgy Bozoki
>
> > -----Original Message-----
> > From: Discussion of advanced .NET topics.
> > [mailto:[EMAIL PROTECTED] On Behalf Of
> James Berry
> > Sent: Thursday, January 03, 2008 04:25
> > To: ADVANCED-DOTNET@DISCUSS.DEVELOP.COM
> > Subject: [ADVANCED-DOTNET] Creating unmanaged DLL from .net
> >
> > I need to make a DLL that can be loaded by unmanaged code.
> > That DLL needs to call some .net functions.
> >
> > Is there an easy way to make a managed DLL entry point
> available from
> > unmanaged code?
> >
> > Best wishes
> > James
> >
> > ===================================
> > This list is hosted by DevelopMentor.  http://www.develop.com
> >
> > View archives and manage your subscription(s) at
> > http://discuss.develop.com
> >
>
> ===================================
> This list is hosted by DevelopMentor?  http://www.develop.com
>
> View archives and manage your subscription(s) at
> http://discuss.develop.com
>
> ===================================
> This list is hosted by DevelopMentor.  http://www.develop.com
>
> View archives and manage your subscription(s) at
> http://discuss.develop.com
>

===================================
This list is hosted by DevelopMentor®  http://www.develop.com

View archives and manage your subscription(s) at http://discuss.develop.com

Reply via email to