Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
C0000005 - Revisited
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
C0000005 - Revisited
Divers
Thread ID:
00184365
Message ID:
00184365
Vues:
42
Hi Gang,

In my recent post on this error (beginning last Tuesday) I stated that I had encountered this error in working with the ImageList control. To recap, I was getting a syntax error on the first pass, I'd make a change, then get the C...5 error. Apparently, I was wrong about it purely being a VFP problem. I believe now that other factors were involved that caused this.

First, I located the cause of the syntax error. While it's documented that you can set location properties within sub-classed ActiveX controls either VFP or the ImageList control don't like it, and it will generate a syntax error. Below is a code sample:
DEFINE cImageList AS OLECONTROL
  * These settings work fine
  .Object.ImageHeight = 16
  .Object.ImageWidth = 17
  .Object.MaskColor = 16777215
  .Object.UseMaskColor = .T.
  * The following do not and will
  * cause a syntax error when AddObject
  * is called
  .Height = 45
  .Left = 141
  .Top = 145
  .Width = 52
ENDDEFINE
* Method code
SET PROCEDURE TO cIList ADDITIVE
* A syntax error results here when the above
* mentioned properties are set
This.AddObject(This.AddObject('ObjImages', "cImageList", "MSComctlLib.ImageListCtrl.2")
Last night I had done some work in VFP and decided to check my email. After retrieving it and responding to an email from Randy Brown, I decided to check some things out because he mentioned that he was unable to reproduce the problem. After sending a response to him, I shut down the Compuserve CIS program (version 3.0.1), which complained as it usually does that it couldn't disconnect because VFP 6.0 was using the connection. I hadn't used VFP to interface with the service, but I'd seen this before and simply manually disconnected. After noticing that I hadn't correctly restored the "offending" code, and made some changes and it worked fine! This was after I had corrected the "syntax error" problem. I tried several times without a problem. I then opened the debugger and tried again. Boom! C0000005 struck again.

This morning prior to coming to work, I tried again, without making any modification and, with or without the debugger open, no problems. I am speculating that somehow, someway that this had something to do with the Compuserve software and the disconnecting problem. I have no way to determine whether or not this is the case. I hasten to add that I am unable to reproduce the problem here at the office, where access to the Internet via the Shaw server. Therefore, the only conclusion that I can reach is that this particular instance of the error is caused by something external to VFP.

My thanks to Randy Brown for his time and interest. My apologies to him for perhaps leading him down a fruitless path.
George

Ubi caritas et amor, deus ibi est
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform