Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP DLLs and IIS 5.0
Message
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Title:
VFP DLLs and IIS 5.0
Miscellaneous
Thread ID:
00438362
Message ID:
00438362
Views:
38
We've developed a VFP multi-threaded DLL that is used in ASP pages for server-side scripting.

We seem to be encountering the following problem, more frequently than we'd like....

In the server side script we may have the following code: (This is only one example)

Dim HCASP
Set HCASP = Server.CreateObject("HCASP.CHCASP")
HCASP.DoSomething()
Set HCASP = Nothing

If the function DoSomething() does not exist in the DLL HCASP, then an error occurs before the line Set HCASP = Nothing is executed. This behavior, of not releasing the object, seems to create memory leaks in IIS??? It may not always "bog" down IIS the first time the error occurs, but after several occurences the site will go down.

The obvious fix to the problem shown above is to make sure the function exists in the HCASP DLL; but if any other type of error is encountered that fails to release the HCASP object, the same result occur.

Placing an "On Error Resume Next" seems to work fine because the "Set HCASP = Nothing" line will be executed, but if any other errors occur on the page we won't know about them...

Has anyone encountered a problem similar to this or have any suggestions?

Thanks,
Tem
Reply
Map
View

Click here to load this message in the networking platform