Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Delete records in a grid
Message
 
 
To
17/12/1998 11:25:10
Carla Silva
Http - Produtos Informaticos, Lda.
Odivelas, Portugal
General information
Forum:
Visual FoxPro
Category:
Troubleshooting
Miscellaneous
Thread ID:
00168534
Message ID:
00168813
Views:
33
>I have a grid populated with a view, the view using update type "SQL DELETE THEN INSERT", the grid have the delete column. if I have a view with 3 records and I delete the record that is in the middle the record is deleted and the tableupdate() is sucessed, if I delete the first and last record I have the error message "Record is out of range", I have the same problem if the recordsource property is a table. Why this happen ?
>
>Thanks
>Carla Silva

What many of us do, is handle the deletion in the DELETED method with code. Something like:
LPARAMETERS nRecNo    && default parameter included by VFP
NoDefault
goto nRecNo
if eof()
   return
endif
delete next 1
=TableUpdate(whatever_parameters_here)
ThisForm.Refresh() or This.Refresh()  && whichever is really needed
Mark McCasland
Midlothian, TX USA
Previous
Reply
Map
View

Click here to load this message in the networking platform