I created a simple dll. I am able to reference and use it from a vb
program, but not from an asp page. This code

Set o = Server.CreateObject("MyLib.MyClass")

gives me this error:

Server object, ASP 0177 (0x800401F3)
Invalid class string

I gave Full Control permission to Everyone to both my dll file and
msvbvm60.dll.
What is going wrong?

Re: DLL from ASP by Steven

Steven
Thu Oct 20 15:01:22 CDT 2005

http://aspfaq.com/show.asp?id=2134

--
Regards

Steven Burn
Ur I.T. Mate Group
www.it-mate.co.uk

Keeping it FREE!

<verb13@hotmail.com> wrote in message
news:1129838151.898291.148190@f14g2000cwb.googlegroups.com...
> I created a simple dll. I am able to reference and use it from a vb
> program, but not from an asp page. This code
>
> Set o = Server.CreateObject("MyLib.MyClass")
>
> gives me this error:
>
> Server object, ASP 0177 (0x800401F3)
> Invalid class string
>
> I gave Full Control permission to Everyone to both my dll file and
> msvbvm60.dll.
> What is going wrong?
>



Re: DLL from ASP by Someone

Someone
Thu Oct 20 15:05:50 CDT 2005

What's your DLL file name and what's the project name?

My guess is that your DLL name is MyLib.dll and you left the project name at
Project1. Try:

Set o = Server.CreateObject("Project1.MyClass")

You could start a new VB project and look in the list of references to see
how your classes are listed.


<verb13@hotmail.com> wrote in message
news:1129838151.898291.148190@f14g2000cwb.googlegroups.com...
>I created a simple dll. I am able to reference and use it from a vb
> program, but not from an asp page. This code
>
> Set o = Server.CreateObject("MyLib.MyClass")
>
> gives me this error:
>
> Server object, ASP 0177 (0x800401F3)
> Invalid class string
>
> I gave Full Control permission to Everyone to both my dll file and
> msvbvm60.dll.
> What is going wrong?
>



Re: DLL from ASP by verb13

verb13
Thu Oct 20 16:37:07 CDT 2005

As I already mentioned, the dll works fine from a vb program.

This works in vb:
Set o = CreateObject("MyLib.MyClass")

This does not work in asp:
Set o = Server.CreateObject("MyLib.MyClass")

The error is:
Server object, ASP 0177 (0x800401F3)
Invalid class string


Re: DLL from ASP by Someone

Someone
Thu Oct 20 22:20:27 CDT 2005

> This works in vb:
> Set o = CreateObject("MyLib.MyClass")

You didn't include this code fragment in your original post, so I assumed
that you added it as a reference, which works differently.


Make sure that you give the IWAM account enough permissions. Also make sure
that it has full permission to the TEMP folder(s).

How to set required NTFS permissions and user rights for an IIS 5.0 Web
server
http://support.microsoft.com/default.aspx?scid=kb;en-us;271071




<verb13@hotmail.com> wrote in message
news:1129844227.014375.15240@g47g2000cwa.googlegroups.com...
> As I already mentioned, the dll works fine from a vb program.
>
> This works in vb:
> Set o = CreateObject("MyLib.MyClass")
>
> This does not work in asp:
> Set o = Server.CreateObject("MyLib.MyClass")
>
> The error is:
> Server object, ASP 0177 (0x800401F3)
> Invalid class string
>



Re: DLL from ASP by verb13

verb13
Fri Oct 21 03:30:36 CDT 2005

I gave Everyone Full Control to my dll, msvbvm60.dll, C:\WINDOWS\Temp,
but the result is the same.


Re: DLL from ASP by Someone

Someone
Fri Oct 21 09:35:06 CDT 2005

Try adding IWAM specifically, not Everyone group. You could add IUSR too,
but reduce its permission later after ruling out the needed permissions.


<verb13@hotmail.com> wrote in message
news:1129883436.916566.51910@g49g2000cwa.googlegroups.com...
>I gave Everyone Full Control to my dll, msvbvm60.dll, C:\WINDOWS\Temp,
> but the result is the same.
>



Re: DLL from ASP by Someone

Someone
Fri Oct 21 11:29:23 CDT 2005

I am not sure if ASP uses the same logic or API function as CreateObject in
VB6. There maybe a conflict in the registry because of IDE crashes or not
using binary compatibility. Go to Project|References and see if your class
is listed more than once, if it is, then you definitely have a problem. Even
if it's listed once, you may find the suggestions in the following article
useful:

PRB: DCOMCNFG Reports Multiple Copies of DCOM Server
http://support.microsoft.com/default.aspx?scid=kb;en-us;180525

Note that the article refers to using DCOMCNFG.EXE in Windows 9x. You can
see the same list of objects by going to Project|References. In newer
versions of Windows, you can see the list of objects in Control
Panel|Administrative Tools|Component Services|Computers|My Computer|DCOM
Config. Typing "DCOMCNFG.EXE" will open "Component Services". You might see
some warnings that some AppID's are not recorded, choose No.

When you run an ActiveX project in the IDE, VB6 creates registry entries and
points them to the following file:

C:\Program Files\Microsoft Visual Studio\VB98\VB6DEBUG.DLL

When you stop the project, the IDE would auto delete these entries, unless
it crashes. When you compile your ActiveX project, VB6 auto create the
registry entries for them and point them to your compiled file. VB6 never
delete these entries, otherwise you can't use your component.

Also, in NT, you have to be a member of Power Users or Administrators in
order to develop and test ActiveX projects. That's because only Power Users
and Administrators can write to HKEY_LOCAL_MACHINE.

INFO: Registry Entries Made by an ActiveX Component
http://support.microsoft.com/default.aspx?scid=kb;en-us;183771


<verb13@hotmail.com> wrote in message
news:1129844227.014375.15240@g47g2000cwa.googlegroups.com...
> As I already mentioned, the dll works fine from a vb program.
>
> This works in vb:
> Set o = CreateObject("MyLib.MyClass")
>
> This does not work in asp:
> Set o = Server.CreateObject("MyLib.MyClass")
>
> The error is:
> Server object, ASP 0177 (0x800401F3)
> Invalid class string
>