Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_databases thread: how do I connect asp pages to .dll files?


Message #1 by "Scott Millett" <scott@m...> on Thu, 24 Aug 2000 21:4:6
I have created an ActiveX DLL project and used it with an asp page to 

connect to a database, it works fine on my machine using PWS but when I 

uploaded all my pages the asp page says it cannot create the 

Server.CreateObject.



How do make my .dll files work on the web?



And how do I modify the following - 



"Data Source=C:\db\Library.mdb"



do I just change it to -



"Data Source=http://www.mywebspace.com/db/Library.mdb" ????



I have been using the example in Beginning VB6 Database Prog p699.



Please can someone help?



Cheers 

Scott



Scott@m...



Message #2 by Imar Spaanjaars <Imar@S...> on Fri, 25 Aug 2000 11:01:28 +0200
You will need to register the DLL's on the webserver. Open a command prompt 

pointing to the directory where your .DLL resides, and then type the following:



regsvr32 yourDllName.dll



If you use a hosting service, they will have to do this for you. If they 

don't allow custom DLL's (most of em don't) then you can't use your DLL's 

in your site. The reason it worked on your local machine, is that 

components get registered when you compile your .DLL.



To get the path of the .MDB, use the Server.MapPath method. This will 

return the full, local path to the database.



Server.MapPath("Library.mdb") will then return "C:\db\Library.mdb", or 

where-ever the .MDB is located.





Imar





At 09:04 PM 8/24/2000 +0000, you wrote:

>I have created an ActiveX DLL project and used it with an asp page to

>connect to a database, it works fine on my machine using PWS but when I

>uploaded all my pages the asp page says it cannot create the

>Server.CreateObject.

>

>How do make my .dll files work on the web?

>

>And how do I modify the following -

>

>"Data Source=C:\db\Library.mdb"

>

>do I just change it to -

>

>"Data Source=http://www.mywebspace.com/db/Library.mdb" ????

>

>I have been using the example in Beginning VB6 Database Prog p699.

>

>Please can someone help?

>

>Cheers

>Scott

>

>Scott@m...





Message #3 by "Scott Millettt" <Scott@m...> on Fri, 25 Aug 2000 21:08:17 +0100
Thank you for your reply,



I wanted to use the .DLL program for an Object Oriented approach to

asp programming, is there another way I can do it?



What I have is a Library type program written in VB that I want to convert

to the

web, can I have different asp pages with different methods, and can I use

them in an

OOP way?



I realise that this is a big question but I would be really happy if you

could help.



Cheers

Scott





----- Original Message -----

From: Imar Spaanjaars 

To: ASP Databases <asp_databases@p...>

Sent: Friday, August 25, 2000 10:01 AM

Subject: [asp_databases] Re: how do I connect asp pages to .dll files?





> You will need to register the DLL's on the webserver. Open a command

prompt

> pointing to the directory where your .DLL resides, and then type the

following:

>

> regsvr32 yourDllName.dll

>

> If you use a hosting service, they will have to do this for you. If they

> don't allow custom DLL's (most of em don't) then you can't use your DLL's

> in your site. The reason it worked on your local machine, is that

> components get registered when you compile your .DLL.

>

> To get the path of the .MDB, use the Server.MapPath method. This will

> return the full, local path to the database.

>

> Server.MapPath("Library.mdb") will then return "C:\db\Library.mdb", or

> where-ever the .MDB is located.

>

>

> Imar

>

>

> At 09:04 PM 8/24/2000 +0000, you wrote:

> >I have created an ActiveX DLL project and used it with an asp page to

> >connect to a database, it works fine on my machine using PWS but when I

> >uploaded all my pages the asp page says it cannot create the

> >Server.CreateObject.

> >

> >How do make my .dll files work on the web?

> >

> >And how do I modify the following -

> >

> >"Data Source=C:\db\Library.mdb"

> >

> >do I just change it to -

> >

> >"Data Source=http://www.mywebspace.com/db/Library.mdb" ????

> >

> >I have been using the example in Beginning VB6 Database Prog p699.

> >

> >Please can someone help?

> >

> >Cheers

> >Scott

> >


  Return to Index