Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Classfactory cannot supply requested class
Message
 
To
29/02/2000 03:13:50
Marco Beuk
Innovero Software Solutions
The Hague, Netherlands
General information
Forum:
Visual FoxPro
Category:
Internet applications
Miscellaneous
Thread ID:
00338974
Message ID:
00338976
Views:
20
Marco,

I've just finished tracking down this exact problem on a DLL.

The issue was that I was returning .f. from the init (because a precondition failed). The precondition failed because I hadn't taken the path changes into consideration. When instantiating a COM component, it doesn't (necessarilly) have its location as its default directory.

In turn, this caused a locfile() (which I hadn't bracketed with _vfp.startmode checks) to fire and there was a UI stuck in the limbo of COM.

Tracking it down got a lot easier when I compiled the COM server as an exe - there was a task in the task list titled "Open"

After that, it was just a matter of writing to a log file at each step through the init method and finding where it got to.

Here's the code I used for writing the log:
*-------------------------------------------------------
* Procedure...: WriteLog
* Called by...:
*
* Abstract....: Writes a debugging message to a log
*
* Parameters..:
*
* Notes.......:
*-------------------------------------------------------
	PROTECTED PROCEDURE writelog

		LPARAMETERS tuMessage

		LOCAL lcMessage
		lcMessage = ALLTRIM(TRAN(tuMessage))

		IF VERS(2) > 0
			DEBUGOUT lcMessage
		ELSE
			LOCAL lcFileName
			lcFileName = ADDBS(SYS(5) + SYS(2003)) + ('DLLError.log')
			STRTOFILE(CHR(13)+CHR(10) + lcMessage, lcFileName, .T.)
		ENDIF

	ENDPROC &&* WriteLog
Then, through the init just pepper plenty of this.writelog('Step 1')

HTH

Cheers,

Andrew


>Hi,
>
>I developed a VFP dll which I want to call from a asp-page.
>The VFP dll works in VFP (createobject) but when I perform the command in the asp-page the following errormessage is returned: Server object, ASP 0177 (0x80040111) Classfactory cannot supply requested class.
>(line 20)
>
>Line 20 has the following code:
>Set oHotel = Server.CreateObject("Hotelcom.Hotels")
>
>I don't know for sure if the dll is proper registered. The dll is in the same directory (on the server) and is created on this server in VFP (and automaticaly registered I presume).
>
>We work with W2000 advanced server.
>
>I hope somebody can give me a hint.
>
>Marco


If we were to introduce Visual FoxBase+, would we be able to work from the dotNet Prompt?


From Top 22 Developer Responses to defects in Software
2. "It’s not a bug, it’s a feature."
1. "I thought I fixed that."


All my FoxTalk and other articles are available on my web site.


Unless specifically identified otherwise, anthing posted here is purely my opinion and may or may not reflect the policies or practices of Microsoft.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform