Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Wierd Behavior - Could be Me
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00569523
Message ID:
00569539
Views:
23
This message has been marked as the solution to the initial question of the thread.
Hi!

A few of suggestions:

1. Try to "Step into" that command. If there is an error handler and error happens in that line, you will see it.

2. ltTestEnd - at that moment chack if current alias does not contain a field with the similar name. When such field exists, VFP6 does not throw ANY error, though assignment to field does not work, of course - you have to use REPLACE command for fields. To distinguish field and variable, use "m.ltTestEnd" - "m." tell VFP that you going to use variable. I always use m. in routines that are generic enough to meet at some moment a field with the same name as one of the variables in the routine.

3. Try to use STORE command. I met a few very rare situations when VFP incorrectly used "RUN" command on place of the "!" that I used as a "NOT" operator. Here it could be that VFP evaluates that line as a comparison instead of assignment. If this is a case, you can send this as a bug to MS ;)

HTH.

>Last night I was working on a form in VFP7, I have a text box that the user enters a length of time in. In the valid method, I check the begining time and the length to make sure it does not conflict with any other records. But each time I ran it, the valid event wasn't returning a conflict even though I knew there was a conflict. I put a set step on in the valid method, and it was hitting my line that calls the conflict check method (ctChkDoc()), but then going to the next line without running it. Yet that same function is called from another form and runs great. I still haven't figured out why it was skipping over that line. With set step on, it never even entered the fuction. Below is the code, and I've put <== marker where the functions were called but didn't fire:
>
>
>* Setup variables for conflict checking
>ltTestStart=schcase.begintime
>ltTestEnd=ltTestStart+ttos(this.value)  <==  Does not call ttos() and doesn't store anything to ltTestEnd
>SELECT meetingprocedures
>lcDocNum=ALLTRIM(meetingprocedures.docnumber)
>* Check for SurgeonConflict
>lcConflict=ctChkDoc(lcDocNum,ltTestStart,ltTestEnd,gnMeetID) <== Never calls function and lcConflict is never populated
>
>
>
>I exitted VFP7 and got back in, ran it again, same results. Compile both ttos and ctChkDoc from command window, no errors. I don't really this this is a bug in VFP as much as maybe I've got something set screwy. Any suggestions where I should start looking would be appreciated.
>
>Kirk
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.com
ICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs

It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform