Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Syntax error tracing
Message
From
01/12/2016 17:35:14
 
 
To
01/12/2016 17:20:19
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 10
Miscellaneous
Thread ID:
01644145
Message ID:
01644224
Views:
30
>>>>>>>Boris (and then Gregory) gave you very simple and correct instructions - why did you try to go in a completely wrong direction?
>>>>>>
>>>>>>Naomi,
>>>>>>
>>>>>>I did follow the instructions of Boris and Gregory:
>>>>>>Have modified my class, and recompiled and now I can read that most of my addobjects error, even the most simple one, I gave an example, here is an other one:
>>>>>>
>>>>>>ADD OBJECT frmaanvraag.kvbasepageframe1.page1.line7 AS line WITH  BorderWidth = 3,  Height = 258,  Left = 867,  Top = 251,  Width = 0,  ZOrderSet = 41,  Name = "Line7"
>>>>>>Error in line 474: Syntax error.
>>>>>>
>>>>>>sorry, but I can't see anything wrong. Do you?
>>>>>>
>>>>>>I am afraid I am facing a corrupt .VCX file and shall have to reconstruct my carefully constructed class.
>>>>>
>>>>>What is that code? Is it something generated within the VCX, or is it method code expected to be run directly by the VFP interpreter?
>>>>>
>>>>>If the latter, is ADD OBJECT a valid VFP command? There's an .AddObject() method but it's significantly different.
>>>>
>>>>Hi Al,
>>>>It is one of the many lines in my .err file.
>>>>Generated by VFP
>>>
>>>The .ERR file is simply reporting the source for a line of code it can't compile. If VFP is trying to compile that line, AFAIK "ADD OBJECT" is not a valid VFP command.
>>>
>>>If that's the case, where did it come from? Do you recall how you added that line to your class?
>>
>>Al,
>>
>>It is not only that line, but also the other line, the other combobox a.s.o. around 260 objects, virtualy all of them.
>>The .err file was generated by compiling my class.
>>The class was converted to a .scx and runned uptill a day ago, I am still 'under construction' without any problems.
>>Now - all of a sudden - when I start the form: it gives me "Syntax error"
>>When I look into my errorlogging I find:
>>
>>1-12-2016 22:56:10 Error: 10
>>Filename: C:\temp\E121601225610log.txt
>>Message: Syntax error.
>>Command:
>>Method:
>>Line: 0
>>Netwerk info: LAPTOPVANKOEN # Piller
>>============================================================
>>
>>notice? no command, no Method, no line
>>I disregard the error and continue to run the form. However this is not correct.
>>Meanwhile I am reconstructing the class and form.
>>
>>My posting here, was to find out, if there would be a more elegant way to fix this error. I can only conclude that I am facing a corrupt class. Too bad.
>
>As Antonio points out, those errors are probably arising because ADD OBJECT clauses are not properly wrapped within a DEFINE CLASS... ENDDEFINE block i.e. either the DEFINE CLASS or ENDDEFINE line is missing.
>
>My understanding is during compilation VFP pulls code out of memo fields in the VCX and processes them row by row. So, one of those clauses missing in just one of the cells might cause multiple compile errors in subsequently processed rows.
>
>It would probably take some effort but you could open the VCX as a table and scan the memo fields looking for missing or improper DEFINE CLASS and ENDDEFINE statements.


Al,

I have reconstructed (saved by the backup). And will not look any further for the reason what happened to my class.
Thanks for the moral support,

Regards,

Koen
Previous
Reply
Map
View

Click here to load this message in the networking platform