-
Nov 27th, 2021, 04:15 AM
#1
Thread Starter
Addicted Member
[RESOLVED] How To Compile code as DLL
hi ~ all
How To Compile code as DLL ( VB.NET )
and the dll can be used in vb6
-
Nov 27th, 2021, 05:28 AM
#2
Re: How To Compile code as DLL
-
Nov 27th, 2021, 06:06 AM
#3
Re: How To Compile code as DLL
Within the Visual Basic .NET's Solution Explorer, click on My Project. If you don't see My Project because the name was changed, click whatever is two down from Solution 'application name' (1 project).
In the Application tab under Application type, select Class Library from it's drop-down menu.
Now rebuild and save the project, and get the dll from the project's debug folder.
-
Nov 27th, 2021, 06:21 AM
#4
Re: How To Compile code as DLL
It takes a little more than that. He asks about using the DLL from a VB6 application.
-
Nov 27th, 2021, 06:25 AM
#5
Thread Starter
Addicted Member
Re: How To Compile code as DLL
Originally Posted by Niya
Can VB.Net compile to Standard DLL ???
-
Nov 27th, 2021, 07:11 AM
#6
Re: How To Compile code as DLL
Originally Posted by quickbbbb
Can VB.Net compile to Standard DLL ???
No. Use C++ for that.
-
Nov 27th, 2021, 07:51 AM
#7
Thread Starter
Addicted Member
Re: How To Compile code as DLL
Originally Posted by Niya
No. Use C++ for that.
OK
thank you
-
Nov 27th, 2021, 07:58 AM
#8
Re: [RESOLVED] How To Compile code as DLL
You know your question piqued my interest so I decided to look into it before I dismiss it as completely impossible and I found some who claim it can be done. You can check out those claims to see if they hold water. You can start here.
-
Nov 27th, 2021, 12:01 PM
#9
Re: How To Compile code as DLL
Originally Posted by Niya
Originally Posted by Peter Porter
Originally Posted by quickbbbb
hi ~ all
How To Compile code as DLL ( VB.NET )
and the dll can be used in vb6
Within the Visual Basic .NET's Solution Explorer, click on My Project. If you don't see My Project because the name was changed, click whatever is two down from Solution 'application name' (1 project).
In the Application tab under Application type, select Class Library from it's drop-down menu.
Now rebuild and save the project, and get the dll from the project's debug folder.
It takes a little more than that. He asks about using the DLL from a VB6 application.
Niya, I didn't see his question as a two-parter, plus the last part reads like he knows what to do with a dll, just needs to know how to create it. It also reads like he started the VB.NET project in winforms, or found the project as so, which is why he needed to know how to convert it to a dll.
Originally Posted by quickbbbb
Can VB.Net compile to Standard DLL ???
Seems like that's all he's asking for, which I answered above in my first reply.
Originally Posted by Niya
Originally Posted by quickbbbb
Can VB.Net compile to Standard DLL ???
No. Use C++ for that.
C++? What am I missing here?
Anyway, before VB.Net is converted to a dll, it's code needs to be configured to work with 32bit applications in order to work with VB6. In the Configuration Manager, under Active Solution platform, if it's not showing x86, open it's drop-down menu and click <New...>, and in the pop-up under Type..., select x86 from it's drop-down menu, and click OK. Now in the Configuration Manager under Platform, if it's not showing x86, open it's drop-down menu and click <New...>, and in the pop-up under Type... select x86 from it's drop-down menu and click OK. Now close the Configuration Manager, rebuild the project, and follow the steps in my first post.
I'm still using Visual Basic 2010, so there might be more hoops to do all of the above in my instructions if you have a newer version of VB.
quickbbbb, if Niya helped you out, just ignore my crazy self.
Last edited by Peter Porter; Nov 27th, 2021 at 01:23 PM.
-
Nov 27th, 2021, 06:58 PM
#10
Re: How To Compile code as DLL
Originally Posted by Peter Porter
C++? What am I missing here?
He wants to export WINAPI/Extern "C" styled functions from the DLL. The C++ compiler has the most straightforward way of doing this.
-
Nov 27th, 2021, 07:02 PM
#11
Re: How To Compile code as DLL
Originally Posted by Niya
He wants to export WINAPI/Extern "C" styled functions from the DLL. The C++ compiler has the most straightforward way of doing this.
Oh, I missed this from another thread, or did you have a private chat with him?
-
Nov 27th, 2021, 07:04 PM
#12
Re: How To Compile code as DLL
Originally Posted by Peter Porter
Oh, I missed this from another thread, or did you have a private chat with him?
No. He said "Standard DLL". Typically what people mean by this is the most common type of DLL which is one that exports WINAPI styled functions like Windows DLLs such as GDI32.Dll or User32.Dll
-
Nov 27th, 2021, 07:09 PM
#13
Re: How To Compile code as DLL
Originally Posted by Niya
No. He said "Standard DLL". Typically what people mean by this is the most common type of DLL which is one that exports WINAPI styled functions like Windows DLLs such as GDI32.Dll or User32.Dll
That one flew over my head! Guess I just stick to programming and posting music videos.
-
Nov 27th, 2021, 07:21 PM
#14
Re: How To Compile code as DLL
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|