Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Deleting records from a grid
Message
From
30/10/2003 06:48:20
 
 
To
30/10/2003 05:17:13
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00844381
Message ID:
00844448
Views:
19
This message has been marked as the solution to the initial question of the thread.
Hi Nicholas.

SET DELETED is on but the grid still shows the deleted record.

In order to have the record disappear, you need to move the record pointer in the grid's RecordSource. The code will do it for you:
lcRecordSource = Thisform.MyGrid.RecordSource 
DELETE IN ( lcRecordSource )
SKIP IN ( lcRecordSource )
IF EOF( lcRecordSource )
  SKIP -1 IN ( lcRecordSource )
ENDIF
Thisform.MyGrid.SetFocus()
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform