I created a simple DLL in VB 6.0 & successfully registered it with the
following command at the Command Prompt:

regsvr32 c:\Inetpub\wwwroot\FetchRecords.dll

I am accessing the DLL in an ASP page with the following code:

<%
Dim strProduct
strProduct=Request.QueryString("product")

Dim objProduct
Set objProduct=Server.CreateObject("FETCH.RECORDS")
objProduct.setString(strProduct)
Response.Write("Price of " & strProduct & " is $")
Response.Write(objProduct.retrieveRecords())
Set objProduct=Nothing
%>

But the above code, when executed, throws a "Invalid ProgID" error.

Where am I going wrong? Please note that registering the DLL using
regsvr32 throws a

DllRegisterServer in c:\Inetpub\wwwroot\FetchRecords.dll succeeded.

message implying that the DLL has registered successfully. In order to
ensure that the component has really been installed in my system, I
executed the following script:

<%
If(IsObject(Server.CreateObject("FETCH.RECORDS"))) Then
Response.Write("Component Installed!")
Else
Response.Write("Component Not Installed!")
End If
%>

but strangely, the above script also generates the "Invalid ProgID"
error. Why so though the DLL has registered successfully (as the DOS
message suggests)?

Lastly, can DLLs be created using VS.NET 7.0 in the same way as they
can be created using VB 6.0?

Thanks,

Arpan

Re: DLL! by Ray

Ray
Mon Jul 11 08:45:58 CDT 2005

Hi Arpan,

Is "FETCH.RECORDS" the class name that you're using when you compile the
dll?

Ray at work

"Arpan" <arpan_de@hotmail.com> wrote in message
news:1120951846.590575.145020@g14g2000cwa.googlegroups.com...
> I created a simple DLL in VB 6.0 & successfully registered it with the
> following command at the Command Prompt:
>
> regsvr32 c:\Inetpub\wwwroot\FetchRecords.dll
>
> I am accessing the DLL in an ASP page with the following code:
>
> <%
> Dim strProduct
> strProduct=Request.QueryString("product")
>
> Dim objProduct
> Set objProduct=Server.CreateObject("FETCH.RECORDS")
> objProduct.setString(strProduct)
> Response.Write("Price of " & strProduct & " is $")
> Response.Write(objProduct.retrieveRecords())
> Set objProduct=Nothing
> %>
>
> But the above code, when executed, throws a "Invalid ProgID" error.
>
> Where am I going wrong? Please note that registering the DLL using
> regsvr32 throws a
>
> DllRegisterServer in c:\Inetpub\wwwroot\FetchRecords.dll succeeded.
>
> message implying that the DLL has registered successfully. In order to
> ensure that the component has really been installed in my system, I
> executed the following script:
>
> <%
> If(IsObject(Server.CreateObject("FETCH.RECORDS"))) Then
> Response.Write("Component Installed!")
> Else
> Response.Write("Component Not Installed!")
> End If
> %>
>
> but strangely, the above script also generates the "Invalid ProgID"
> error. Why so though the DLL has registered successfully (as the DOS
> message suggests)?
>
> Lastly, can DLLs be created using VS.NET 7.0 in the same way as they
> can be created using VB 6.0?
>
> Thanks,
>
> Arpan
>



Re: DLL! by Mark

Mark
Mon Jul 11 10:15:52 CDT 2005

VB dlls register classes as <dll name>.<class name>.

your prog_id should be something like "fetchrecords.myclassname".

--
Mark Schupp



"Arpan" <arpan_de@hotmail.com> wrote in message
news:1120951846.590575.145020@g14g2000cwa.googlegroups.com...
> I created a simple DLL in VB 6.0 & successfully registered it with the
> following command at the Command Prompt:
>
> regsvr32 c:\Inetpub\wwwroot\FetchRecords.dll
>
> I am accessing the DLL in an ASP page with the following code:
>
> <%
> Dim strProduct
> strProduct=Request.QueryString("product")
>
> Dim objProduct
> Set objProduct=Server.CreateObject("FETCH.RECORDS")
> objProduct.setString(strProduct)
> Response.Write("Price of " & strProduct & " is $")
> Response.Write(objProduct.retrieveRecords())
> Set objProduct=Nothing
> %>
>
> But the above code, when executed, throws a "Invalid ProgID" error.
>
> Where am I going wrong? Please note that registering the DLL using
> regsvr32 throws a
>
> DllRegisterServer in c:\Inetpub\wwwroot\FetchRecords.dll succeeded.
>
> message implying that the DLL has registered successfully. In order to
> ensure that the component has really been installed in my system, I
> executed the following script:
>
> <%
> If(IsObject(Server.CreateObject("FETCH.RECORDS"))) Then
> Response.Write("Component Installed!")
> Else
> Response.Write("Component Not Installed!")
> End If
> %>
>
> but strangely, the above script also generates the "Invalid ProgID"
> error. Why so though the DLL has registered successfully (as the DOS
> message suggests)?
>
> Lastly, can DLLs be created using VS.NET 7.0 in the same way as they
> can be created using VB 6.0?
>
> Thanks,
>
> Arpan
>



Re: DLL! by Arpan

Arpan
Mon Jul 11 15:01:11 CDT 2005

I am extremely sorry, friends....the DLL is named Fetch.dll & NOT
FetchRecords.dll as mentioned earlier i.e. I registered it using the
following syntax:

regsvr32 c:\Inetpub\wwwroot\Fetch.dll

Also forgot to mention that the class is named "Records".

Sorry, mates, once again & thanks to both of you.

Regards,

Arpan