|
-
Apr 25th, 2005, 08:16 AM
#1
Thread Starter
Member
DLL through ASP.NET
hi everyone
is there any way of making a .DLL using asp.net...i m trying to put some code in the DLL( not the .vb extension class)...and i will hook the code in 'codebehind' with the DLL.
i think DLLs r possible through c#, vb.net, win32 project and even VB has ActiveX DLL...but how to do it in asp.net
thnx
yash.
-
Apr 26th, 2005, 03:41 PM
#2
I wonder how many charact
Re: DLL through ASP.NET
1) Right-click your 'SOLUTION' in the Solution Explorer, choose Add New Project, Class Library.
2) Put the code you want in there
3) In your Web project (NOT THE SOLUTION, and NOT THE CLASS LIBRARY YOU JUST ADDED), right-click References, then Add Reference...
when the dialog box appears, click the Projects Tab, select the Class Libary you just created (so that it appears in the bottom area of the dialog box, then click OK).
4) In any page you use your class library, you must put an Imports ClassLibrary1 (or whatever you named your libary).
-
Apr 27th, 2005, 01:39 AM
#3
Thread Starter
Member
Re: DLL through ASP.NET
thnx for the reply nemaroller..
but is this what we call as DLL...this file is with extension .vb...i have used these quite a lot in my project...but i m looking for the conventional .DLL files...can those be made somehow..
thnx again.
-
Apr 27th, 2005, 09:19 AM
#4
I wonder how many charact
Re: DLL through ASP.NET
Well, no the dll does not have a vb extension.
It is managed code however, and I'm guessing your wondering how to use an existing umanaged dll within a .Net application. If you're instead wondering how to create a new dll in unmanaged code, well then you will have to use C++ to do so, and then add the existing item to your project.
http://www.codeproject.com/csharp/unmanage.asp
Last edited by nemaroller; Apr 27th, 2005 at 09:25 AM.
-
Apr 29th, 2005, 10:57 AM
#5
Hyperactive Member
Re: DLL through ASP.NET
To make a Dll you write the code in .vb file...and then compile it.../t: (is used to specify that you want it as dll)
You can compile the VB.NET code with this:
vbc /t:library /out..\bin\SQLDb.dll /r:System.dll /r:System.Data.dll Database.vb
Then you can call the dll through your asp.net page by creating an instance of it.
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
|