![]() |
|
[.NET] [TUT] Create a DLL and Use It In Your Application [VB.NET] - Printable Version +- Hack Forums (https://hackforums.net) +-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444) +--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151) +---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118) +---- Thread: [.NET] [TUT] Create a DLL and Use It In Your Application [VB.NET] (/showthread.php?tid=620192) |
[TUT] Create a DLL and Use It In Your Application [VB.NET] - Ĥ4Ж0Ŕ - Aug 18, 2010 Hi Guys Today I'll show you how to create a DLL and use it in your application instead of writing the full code in your project. Step 1: Create a New Class Library as Shown below Spoiler (Click to View) Step 2: Name the class as you want then add your code as shown below Spoiler (Click to View) As you can see, my code is a simple Math operations and you can add your own code. So let's build it and close VS. You'll find your dll in the release folder Step 3: Now our Dll is ready to use so let's make an application which will use the Dll. Spoiler (Click to View) Step 4: Now we have to add a reference to our Dll GoTo Project -> Add Reference, and browse to where your Dll is located. Spoiler (Click to View) Step 5: Ok, Now let's write our application and don't forget to import the Dll Spoiler (Click to View) Now we're done. so let's compile the project and test it. Result: Spoiler (Click to View) Ok, that's it. Now I need your feedback Thanks for reading🤝 * - DisconnectionModsss - Aug 18, 2010 Thanks i was looking for something like this. * - Ĥ4Ж0Ŕ - Aug 18, 2010 (Aug 18, 2010 01:13 PM)Exotic™ Wrote: Thanks i was looking for something like this. You're welcome buddy 🤝 * - The End Gamer - Aug 18, 2010 Very Nice Tutorial! Thanks :D * - Ĥ4Ж0Ŕ - Aug 18, 2010 (Aug 18, 2010 01:17 PM)The End Gamer Wrote: Very Nice Tutorial!you're welcome bro! I hope you've learned something. * - Meerds1 - Aug 18, 2010 hehe nice ;) can i actually put everykind of code in it .. example i could place there a sub ? example the sub with file open etc..? * - Aeonhack Archivist - Aug 18, 2010 You don't even need to have Class1.vb or whatever it is that is created when you make the project. You can trash that and add a UserControl if you don't want to program. It will still compile as a DLL and works just fine. * - Ĥ4Ж0Ŕ - Aug 18, 2010 (Aug 18, 2010 03:23 PM)Meerds1 Wrote: hehe nice ;) can i actually put everykind of code in it .. example i could place there I believe you can bro! This just an example where I'm using functions and you can put whatever you want and if you're familiar with GDI you can create some cool controls such as themes, buttons....etc and compile it as a dll 😉 (Aug 18, 2010 03:25 PM)alecn1519 Wrote: You don't even need to have Class1.vb or whatever it is that is created when you make the project. You can trash that and add a UserControl if you don't want to program. It will still compile as a DLL and works just fine. I'm not sure on what dll you're talking about but if you're talking about that one which is located the debug or release folder then you're totally wrong😠. it's not even a dll. * - Aeonhack Archivist - Aug 18, 2010 If you create a Class Library and not a Windows Form App, when you compile, it should create a DLL and not an EXE. What I meant by "Class1.vb" was the default file that is created when you make a new Class Library. You don't have to manually code everything. For people who don't feel confident in doing that, they can delete the default file and add a New UserControl and create their control on there. When they compile it, it should compile as a DLL. * - Oxycodone - Aug 18, 2010 Nice, i just made my 1st dll that works lmfao, i made a web client dll that makes getting / downloading shit easier (just as a test) * - Sector9 - Aug 18, 2010 I love dlls. Thanks you for the simple tut, hopefully people will learn from this :D * - ЄĿĪŦЄ $ØĿÐĪЄR - Aug 19, 2010 great tut,thankyou this is a good tut * - d3c0mpil3r - Aug 19, 2010 Interesting stuff ! Thanks for sharing * - Ĥ4Ж0Ŕ - Aug 19, 2010 (Aug 18, 2010 06:56 PM)Rock Wrote: Nice, i just made my 1st dll that works lmfao, i made a web client dll that makes getting / downloading shit easier (just as a test) Good for you buddy! keep it up 👍 * - zyvox - Aug 19, 2010 Nice tut, thanks =) I needed the code for calc lol jk but still good tut =d |