Registering a dll within VB code
I've a VB Program. Im using some dll with in my code. But to use this dll i nee d to register it. Can i do this within my VB code itself?. That is i'm trying to register the dll with regsvr32.exe while my project getting loaded. How can i do this?.
thanks.
Re: Registering a dll within VB code
I think you are asking about executing your app in other machine...If so, you need to create a setup program and deploy you app using that setup. It will install and register all the files required for your app.
Re: Registering a dll within VB code
Add Ref to TypeLib Info to your vb project and add following lines of code to register
Dim pTLIAplication As New TLI.TLIApplication
Dim pTypeLibInfo As TLI.TypeLibInfo
Set pTypeLibInfo = pTLIAplication.TypeLibInfoFromFile("C:\your Dll Path\a.dll")
pTypeLibInfo.Register
Re: Registering a dll within VB code
the simple method to register a file would be using Shell
Re: Registering a dll within VB code
To use a dll, register it once with regsrv32.exe. Then in your project, go to Project -> References and either browse for it or select from the list.
For the benefit of helpful people, when someone writes they have a dll, it means they have a dll not a Typelib. When they talk about loading their project, that in no way refers to another computer. A basic understanding of VB would be useful before answering VB posts.
Re: Registering a dll within VB code
Quote:
Originally Posted by tduraipkt
Can i do this within my VB code itself?.
He wanted to register the dll within HIS VBCODE
Quote:
Originally Posted by Doom
To use a dll, register it once with regsrv32.exe. Then in your project, go to Project -> References and either browse for it or select from the list
This is not using VBCODE
Quote:
Originally Posted by Doom
A basic understanding of VB would be useful before answering VB posts
who :confused: