Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SelStart function
Message
From
29/03/2006 12:48:51
 
 
To
20/02/2006 12:24:55
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 6 SP5
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01097121
Message ID:
01108891
Views:
32
If I can I would like to get back on this issue because the users of my app are really complaining. I have done a few more tests and have narrowed down the when part but not the why part.

Form Set up:

main form fields for one record(Inspection Record - Header data)
grid holds child records(Inspection Items)

grid is located in a pageframe along with a button to add a child record and a button to save a child record.

Form edit behavior:(That works)

Form appears with cursor in first editable field and has focus
User Clicks in a grid cell, edits the data

Cell Code:

GotFocus
If ThisForm.currentrecordnumber <> getFAIItemQuery.recseq Then
If ThisForm.PageFrame1.Page1.Command1.Enabled = .T. And ThisForm.recordcheck = .F. Then
MessageBox("Did you forget to 'Save Item Data' on the last row you modified?")
ThisForm.recordcheck = .T.
EndIf

ThisForm.currentrecordnumber = getFAIItemQuery.recseq
EndIf

InteractiveChange
ThisForm.statuschangeid = getFAIItemQuery.inspectid
ThisForm.PageFrame1.Page1.Command1.Enabled = .T.(Save Button)
ThisForm.itemupdateflag = .T.

At this time a timer begins to fire, flashing a red container around the save button.

THIS WORKS FINE even with interactiveChange code.

However,

If the user clicks in a grid cell(may or may not do any typing), then into a main form control(say they forgot to fill in a text box), now they click back into the grid cell they left at the end of the string. When a key stoke is made the cursor will jump back to the begining of the string. This will not happen if the user clicks into any other grid cell before they click into the one that had focus or click the cell twice.

If I turn the interactiveChange code off in the cell control this does not happen. But why would it work ok in the first situation.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform