Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Making A VB DLL 1

Status
Not open for further replies.

mavest

Programmer
Feb 27, 2003
54
US
I need to call a VB dll from, of all things, a REXX program. It has been pointed out to me that using the Dependency Walker on my newly made DLL indicates that the functions of interest have not been EXPOSED. It is for certain that I do not see them in the Dependency Walker even though they are Public and have tried different instancing.

Does anyone have a suggestion?
 
Er ... VB DLLs are COM DLLs, not 'classic' DLLs (which, as far as I know, means that you'd need Object REXX rather than classic REXX) - and Dependancy Walker does not show COM interfaces
 
Thanks!

That is most probably the problem. I did also find a post about using C++ to buffer between VB and another calling app. I may have to do this, as using Object Rexx is out of the question.

Too bad there is no syntax or command that can be used to convert the VB function to a classic type.
 
I took a quick look at the suggestion from Lord Sinclair and it sounds similar to what a co-worker is now sending me. According to a co-worker there is a tool available that is a stand-in for the VB linker and will alter the parameter list to the linker. According to my co-worker this is what you do.

1. compile this tool as linker.exe.
2. re-name the real vb linker as linker1.exe
3. the second part of the tool is an add-in that adds some expected subroutines to your vb dll.
4. when you compile / link vb will send its parameter list to the fake linker. The fake linker will edit the parameter list to that of a CLASSIC dll and pass that parameter list on to the real linker - now named linker1.

Well I'll let you know when I try it today or tomorrow.

Bye
 
Google vbadvance. It is a tool for creating 'normal dlls' from vb. Have not tried it myself but have heard that it works well.

Good luck

Jake
 
To All:

I have tested the method / tool located at the below link.


If you go here I would suggest not using the version directly available at this link, but going on to the/any updated versions that the author might have.

Observation: Although I am not a germantic speaker, what I have found at planetsourcecode seems nearly identical to what was available at the German language website of:


Suggested to me by sinclair71. Thanks!

I will say that the website has much more description on how and what to do. So it is certainly worth looking at even if you don't speak german.

RESULT: I had success all the way up to where REXX made the call. I successfully created what appeared to be a classic DLL and was shown by the DependencyWalker to have the proper exported functions. I was also able to call this DLL from VB by using the DECLARE syntax. However, I still had problems on the REXX side using the same REXX syntax that I've used to call other classic DLLs. Today, I will investigate this further and may try Google vbadvance. Tomorrow, I'll post with today's results. Thanks everyone for your help! and I do feel that this is a worthy subject for Tek-Tips!


-Mike
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top