Re: Exporting function from EXE problem
- From: "German Koninin" <nomail@xxxxxxxxxxxxx>
- Date: Thu, 23 Nov 2006 11:33:58 +0100
No, I think that's Ok for me. Mainly I need to run this function from
ActiveX component which is actually DLL. Only for testing reasons I was
trying to call this function from EXE. but in this case I switch my testing
routine into DLL and envelop it into EXE. So I try it. Thank you all. I let
you know here in this thread if any problem. Thanks again!
"Doug Harrison [MVP]" <dsh@xxxxxxxx> wrote in message
news:ua56m25ilific93nfkec46t7rutt4j1foh@xxxxxxxxxx
On Mon, 20 Nov 2006 15:48:05 +0100, "German Koninin"
<nomail@xxxxxxxxxxxxx>
wrote:
Good afternoon.
My problem is that I'm trying to export a function from my EXE.
LoadLibrary
and GetProcAddress wrks fine, but when I call function I'm getting access
violation error. I mean when function is empty or I have some simple code
there like int q = 0; it works fine, but when I initialize a class or
simple
call another function I'm getting access violation. It looks like exe is
not
loaded correctly in to caller's address space or something like that.
Could
you please help me to sort it out. The point is that I need exe with
exported function and need to be able to call that function from other exe
or dll by dynamic linking.
It won't work for the reasons given by Tom and Tim. However, a DLL loaded
into an EXE's process can GetProcAddress a function exported from the EXE
and call that function, though it usually makes more sense for the EXE to
pass information into the DLL directly.
--
Doug Harrison
Visual C++ MVP
.
- References:
- Exporting function from EXE problem
- From: German Koninin
- Re: Exporting function from EXE problem
- From: Doug Harrison [MVP]
- Exporting function from EXE problem
- Prev by Date: Re: Conditional compilation in complex project hierarchy
- Next by Date: Re: How to create a new process without the context of the calling process
- Previous by thread: Re: Exporting function from EXE problem
- Next by thread: Re: Exporting function from EXE problem
- Index(es):
Relevant Pages
|