By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,703 Members | 1,400 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,703 IT Pros & Developers. It's quick & easy.

DLL Function Export

P: n/a
Hello,

I've been given this totally cool website:
http://translate.google.com/translat...ngpair=de%7Cen

And I need to find a way to export functions from DLL compiled by VB. I am
quite new to VB and while this site is translated into English, I have a hard
time figuring out how to use the "Controller-Linker" application. I've been
trying to make an 'educated guess' but for that I need to know the process
involved. Is there someone who understands the process better than me who
can suggest how to use this application? Thank you very much.

Victor.
Nov 21 '05 #1
Share this Question
Share on Google+
9 Replies


P: n/a
I'm sorry, but what is your question? how to export methods from a dll?
that's not in your control -- if the original author wrote a visible
function, then it is already exported.

as far as using the function in VB.NET, in some cases, simply adding a
refernce to the object works -- in others you will use the DllImport
attribute (see
<http://msdn2.microsoft.com/library/e4takf5s(en-us,vs.80).aspx>)

Cheers.
---
http://code.box.sk
nemo me impune lacessit

*** Sent via Developersdex http://www.developersdex.com ***
Nov 21 '05 #2

P: n/a
Hi,

Thank for the reply. Basically, I am writing my own DLL and would like to
export a function. So, I am the "original author". The site which I
reference has a solution to exporting a function (I think) but I am not sure
how to use the "controller-linker" application because I am not sure what
exactly I should type as a command in that application. I will definitely
consider your advice but if you don't mind, please let me know what I should
enter as text for "controler-linker" function in

http://translate.google.com/translat...ngpair=de%7Cen

Thank you so much.

Victor.

"c j anderson" <c j anderson>, "mcp" wrote:
I'm sorry, but what is your question? how to export methods from a dll?
that's not in your control -- if the original author wrote a visible
function, then it is already exported.

as far as using the function in VB.NET, in some cases, simply adding a
refernce to the object works -- in others you will use the DllImport
attribute (see
<http://msdn2.microsoft.com/library/e4takf5s(en-us,vs.80).aspx>)

Cheers.
---
http://code.box.sk
nemo me impune lacessit

*** Sent via Developersdex http://www.developersdex.com ***

Nov 21 '05 #3

P: n/a
"victorsk" <vi******@discussions.microsoft.com> schrieb:
I've been given this totally cool website:
http://translate.google.com/translat...ngpair=de%7Cen

And I need to find a way to export functions from DLL compiled by VB. I
am
quite new to VB and while this site is translated into English, I have a
hard
time figuring out how to use the "Controller-Linker" application. I've
been
trying to make an 'educated guess' but for that I need to know the process
involved. Is there someone who understands the process better than me who
can suggest how to use this application?


Note that the page contains a download on the bottom containing all the
projects and code. The controller project will create a "link.exe". In the
VB6 installation directory, rename the existing "link.exe" to "link1.exe"
(and make a backup of "link.exe") and copy the "link.exe" you created by
compiling the project contained in the download into the directory. VB will
call the custom "link.exe" when compiling, and this "link.exe" will set
required parameters and call "link1.exe".

However, note that this approach is in no way supported!

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #4

P: n/a
Hi,

Thank you again for the reply. Sorry, I am quite new to VB so I appreciate
your patience (and help) with this. What I understand is that there is a
"link.exe" that comes with Visual Studio. Is this app attempting to use this
"link.exe" or is it creating a custom version "link1.exe"? Or, is "link.exe"
compiled by this app a custom version? If this is the case then I am
supposed to rename the custom "link.exe" to "link1.exe"? And, lastly, what
should I enter in "Controller-Linker" dialog box? Sorry, I am asking too
many questions, but I'll really appreciate your clarification on:

1) which directory I should store "link.exe" after renaming it to "link1.exe"
2) what to enter inside "Controller-Linker" dialog box.

Thank you for all your help,
Victor.
"Herfried K. Wagner [MVP]" wrote:
"victorsk" <vi******@discussions.microsoft.com> schrieb:
I've been given this totally cool website:
http://translate.google.com/translat...ngpair=de%7Cen

And I need to find a way to export functions from DLL compiled by VB. I
am
quite new to VB and while this site is translated into English, I have a
hard
time figuring out how to use the "Controller-Linker" application. I've
been
trying to make an 'educated guess' but for that I need to know the process
involved. Is there someone who understands the process better than me who
can suggest how to use this application?


Note that the page contains a download on the bottom containing all the
projects and code. The controller project will create a "link.exe". In the
VB6 installation directory, rename the existing "link.exe" to "link1.exe"
(and make a backup of "link.exe") and copy the "link.exe" you created by
compiling the project contained in the download into the directory. VB will
call the custom "link.exe" when compiling, and this "link.exe" will set
required parameters and call "link1.exe".

However, note that this approach is in no way supported!

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #5

P: n/a
"victorsk" <vi******@discussions.microsoft.com> schrieb:
Thank you again for the reply. Sorry, I am quite new to VB so I
appreciate
your patience (and help) with this. What I understand is that there is a
"link.exe" that comes with Visual Studio. Is this app attempting to use
this
"link.exe" or is it creating a custom version "link1.exe"? Or, is
"link.exe"
compiled by this app a custom version? If this is the case then I am
supposed to rename the custom "link.exe" to "link1.exe"? And, lastly,
what
should I enter in "Controller-Linker" dialog box? Sorry, I am asking too
many questions, but I'll really appreciate your clarification on:

1) which directory I should store "link.exe" after renaming it to
"link1.exe"
2) what to enter inside "Controller-Linker" dialog box.


Untested:

Open "%PROGRAMFILES%\Microsoft Visual Studio\VB98" in explorer, make a
backup of the existing "LINK.EXE", rename the existing "LINK.EXE" to
"LINK1.EXE". Then create a DEF file which contains the list of exported
functions (see article or
<URL:http://msdn.microsoft.com/library/en-us/vccore98/HTML/_core_module.2d.definition_files.asp>).
Compile the project contained in the download mentioned previously and copy
the resulting "link.exe" into the "%PROGRAMFILES%\Microsoft Visual
Studio\VB98" directory. Then simply compile your VB project and choose
"Yes" in the messagebox. A dialog box with a textbox appears. Enter the
name of the DEF file there and press "OK".

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #6

P: n/a
Hi,

Awesome! thanks for the instructions. I'll try to implement them. Sorry
for being a nuisance :-)

Victor.

"Herfried K. Wagner [MVP]" wrote:
"victorsk" <vi******@discussions.microsoft.com> schrieb:
Thank you again for the reply. Sorry, I am quite new to VB so I
appreciate
your patience (and help) with this. What I understand is that there is a
"link.exe" that comes with Visual Studio. Is this app attempting to use
this
"link.exe" or is it creating a custom version "link1.exe"? Or, is
"link.exe"
compiled by this app a custom version? If this is the case then I am
supposed to rename the custom "link.exe" to "link1.exe"? And, lastly,
what
should I enter in "Controller-Linker" dialog box? Sorry, I am asking too
many questions, but I'll really appreciate your clarification on:

1) which directory I should store "link.exe" after renaming it to
"link1.exe"
2) what to enter inside "Controller-Linker" dialog box.


Untested:

Open "%PROGRAMFILES%\Microsoft Visual Studio\VB98" in explorer, make a
backup of the existing "LINK.EXE", rename the existing "LINK.EXE" to
"LINK1.EXE". Then create a DEF file which contains the list of exported
functions (see article or
<URL:http://msdn.microsoft.com/library/en-us/vccore98/HTML/_core_module.2d.definition_files.asp>).
Compile the project contained in the download mentioned previously and copy
the resulting "link.exe" into the "%PROGRAMFILES%\Microsoft Visual
Studio\VB98" directory. Then simply compile your VB project and choose
"Yes" in the messagebox. A dialog box with a textbox appears. Enter the
name of the DEF file there and press "OK".

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #7

P: n/a
Hi,

Awesome! Thanks for the instructions. I'll try to implement them. Sorry
for being a nuisance :-)

Victor.

"Herfried K. Wagner [MVP]" wrote:
"victorsk" <vi******@discussions.microsoft.com> schrieb:
Thank you again for the reply. Sorry, I am quite new to VB so I
appreciate
your patience (and help) with this. What I understand is that there is a
"link.exe" that comes with Visual Studio. Is this app attempting to use
this
"link.exe" or is it creating a custom version "link1.exe"? Or, is
"link.exe"
compiled by this app a custom version? If this is the case then I am
supposed to rename the custom "link.exe" to "link1.exe"? And, lastly,
what
should I enter in "Controller-Linker" dialog box? Sorry, I am asking too
many questions, but I'll really appreciate your clarification on:

1) which directory I should store "link.exe" after renaming it to
"link1.exe"
2) what to enter inside "Controller-Linker" dialog box.


Untested:

Open "%PROGRAMFILES%\Microsoft Visual Studio\VB98" in explorer, make a
backup of the existing "LINK.EXE", rename the existing "LINK.EXE" to
"LINK1.EXE". Then create a DEF file which contains the list of exported
functions (see article or
<URL:http://msdn.microsoft.com/library/en-us/vccore98/HTML/_core_module.2d.definition_files.asp>).
Compile the project contained in the download mentioned previously and copy
the resulting "link.exe" into the "%PROGRAMFILES%\Microsoft Visual
Studio\VB98" directory. Then simply compile your VB project and choose
"Yes" in the messagebox. A dialog box with a textbox appears. Enter the
name of the DEF file there and press "OK".

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #8

P: n/a
Hi,

Awesome! Thanks for the instructions. I'll try to implement them. Sorry
for being a nuisance :-)

Victor.
"Herfried K. Wagner [MVP]" wrote:
"victorsk" <vi******@discussions.microsoft.com> schrieb:
Thank you again for the reply. Sorry, I am quite new to VB so I
appreciate
your patience (and help) with this. What I understand is that there is a
"link.exe" that comes with Visual Studio. Is this app attempting to use
this
"link.exe" or is it creating a custom version "link1.exe"? Or, is
"link.exe"
compiled by this app a custom version? If this is the case then I am
supposed to rename the custom "link.exe" to "link1.exe"? And, lastly,
what
should I enter in "Controller-Linker" dialog box? Sorry, I am asking too
many questions, but I'll really appreciate your clarification on:

1) which directory I should store "link.exe" after renaming it to
"link1.exe"
2) what to enter inside "Controller-Linker" dialog box.


Untested:

Open "%PROGRAMFILES%\Microsoft Visual Studio\VB98" in explorer, make a
backup of the existing "LINK.EXE", rename the existing "LINK.EXE" to
"LINK1.EXE". Then create a DEF file which contains the list of exported
functions (see article or
<URL:http://msdn.microsoft.com/library/en-us/vccore98/HTML/_core_module.2d.definition_files.asp>).
Compile the project contained in the download mentioned previously and copy
the resulting "link.exe" into the "%PROGRAMFILES%\Microsoft Visual
Studio\VB98" directory. Then simply compile your VB project and choose
"Yes" in the messagebox. A dialog box with a textbox appears. Enter the
name of the DEF file there and press "OK".

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #9

P: n/a
Hi,

Awesome! Thanks for the instructions. I'll try to implement them. Sorry
for being a nuisance :-)

Victor.
"Herfried K. Wagner [MVP]" wrote:
"victorsk" <vi******@discussions.microsoft.com> schrieb:
Thank you again for the reply. Sorry, I am quite new to VB so I
appreciate
your patience (and help) with this. What I understand is that there is a
"link.exe" that comes with Visual Studio. Is this app attempting to use
this
"link.exe" or is it creating a custom version "link1.exe"? Or, is
"link.exe"
compiled by this app a custom version? If this is the case then I am
supposed to rename the custom "link.exe" to "link1.exe"? And, lastly,
what
should I enter in "Controller-Linker" dialog box? Sorry, I am asking too
many questions, but I'll really appreciate your clarification on:

1) which directory I should store "link.exe" after renaming it to
"link1.exe"
2) what to enter inside "Controller-Linker" dialog box.


Untested:

Open "%PROGRAMFILES%\Microsoft Visual Studio\VB98" in explorer, make a
backup of the existing "LINK.EXE", rename the existing "LINK.EXE" to
"LINK1.EXE". Then create a DEF file which contains the list of exported
functions (see article or
<URL:http://msdn.microsoft.com/library/en-us/vccore98/HTML/_core_module.2d.definition_files.asp>).
Compile the project contained in the download mentioned previously and copy
the resulting "link.exe" into the "%PROGRAMFILES%\Microsoft Visual
Studio\VB98" directory. Then simply compile your VB project and choose
"Yes" in the messagebox. A dialog box with a textbox appears. Enter the
name of the DEF file there and press "OK".

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #10

This discussion thread is closed

Replies have been disabled for this discussion.