1. WIN32 DLL Question


Where is a example of creating a windows dll ?
The only example is the Linux shared object demo.
I can not find any detail info in the manual about writing DLL internal code.
For instance how do you do initialization of the internal code when the dll first loads ?
I understand that you can create a dll with "C" translator
but I would like to have little more information than that.

Thank You.

new topic     » topic index » view message » categorize

2. Re: WIN32 DLL Question

bugfinder said...


Where is a example of creating a windows dll ?
The only example is the Linux shared object demo.
I can not find any detail info in the manual about writing DLL internal code.
For instance how do you do initialization of the internal code when the dll first loads ?
I understand that you can create a dll with "C" translator
but I would like to have little more information than that.

Do you mean a dll that's translated euphoria code? The translator takes care of that stuff for you. Just write your code and translate away.

Matt

new topic     » goto parent     » topic index » view message » categorize

3. Re: WIN32 DLL Question

bugfinder said...


Where is a example of creating a windows dll ?
The only example is the Linux shared object demo.
I can not find any detail info in the manual about writing DLL internal code.
For instance how do you do initialization of the internal code when the dll first loads ?
I understand that you can create a dll with "C" translator
but I would like to have little more information than that.

Thank You.

It's identical as the Linux shared object demo. There is no difference.

I am not sure how to do initialization on dll load. You can do that by manually editing the generated C, of course.

new topic     » goto parent     » topic index » view message » categorize

4. Re: WIN32 DLL Question

jimcbrown said...

I am not sure how to do initialization on dll load. You can do that by manually editing the generated C, of course.

Maybe in 4.1 we should plan on having a method that is called when the DLL is loaded? an Init() procedure/function.

Jeremy

new topic     » goto parent     » topic index » view message » categorize

5. Re: WIN32 DLL Question

jeremy said...
jimcbrown said...

I am not sure how to do initialization on dll load. You can do that by manually editing the generated C, of course.

Maybe in 4.1 we should plan on having a method that is called when the DLL is loaded? an Init() procedure/function.

Jeremy

I looked at this again, and it turns out you simply leave any code you want to run on dll load at the top level, outside of any function. Any top level code is executed when the dll is loaded.

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu