General information
Category:
The Mere Mortals Framework
I have thrown in the towel and am again going to ask for assistance with this problem. It seems that I am just not able to create COM objects which will work from ASP. I have used MM to create an object based on cApplicationCOM, which I seemingly didn't have a problem. To this class, I added the proverbial (sp) SayHello function which simply returns 'Hello World!'. After making the class OLEPublic, I compiled it using BUILD MTDLL ... I then went into VB (using ASP directly is a pain when you keep rebuilding the DLL and I have found I generally get the same errors) and create a simple form with a button and a label, you click the button and 'Hello World' is supposed to popup on the label. Well, this works just fine on the first click of the button, however, on the second click (without quitting not VB, but the app), I consistently get the error "Error in cRegistry.Init, line 94" which, upon inspection, contains the code:
IF TYPE('goApp') == 'O'
IF TYPE('goApp.oRegistrySetting') != 'O' OR ;
ISNULL(goApp.oRegistrySetting)
goApp.oRegistrySetting = This
ENDIF
ENDIF
It would seem that despite the fact the the object dosen't exist, and neither should goApp as the variable referencing the VFP class is
'Set MyVar = Nothing' at the end of the code, the reference still exists. To make sure that I didn't do something wrong, I created a .PRG file containing:
DEFINE CLASS MyTest AS LINE (or CUSTOM, it doesn't matter) OLEPUBLIC
FUNCTION SayHello
RETURN 'Hello World!'
ENDFUNC
I then use this class in the same VB code and it works every time! What am I missing? It would seem that some property/object is not being released in the MM version of my class, but I can't find out what I am doing wrong! Any help is appreciated!
Justin Spies
ENDDEFINE
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only