Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Pack & grid in a form
Message
From
14/04/2002 12:45:44
Mike Yearwood
Toronto, Ontario, Canada
 
 
To
14/04/2002 08:57:20
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00644723
Message ID:
00644839
Views:
14
Hi

I suggest you consider using a view. Then you don't have to unbind to pack.

This website suggests packing isn't something done regularly. IOW, after deleting a record from the grid, it can become a performance problem to pack if there are lots of records.

http://fox.wikis.com/wc.dll?Wiki~VFPMisusedAndAbused~VFP


>Thanks both of you to help to solve my problem.
>Power
>
>
>>In a form, I have a grid (record source is Table A), a delete button to delete a record and a label to show the total no. of record (by using reccount())
>>>I want to use the label to show the most update of no. of record.
>>>My problem is if I add "pack" after my delete code, it will make my grid become blank.
>>>If I don't add "pack" to my code, the label will show the no. of record including the deleted record. So what can I do?
>>

>>
>>
>>Hi Power,
>>
>>If you want to pack, you can unbind the recordsource, pack, then rebind and you won't loose the grid...
>>
>>
>>ThisForm.myGrid.RecordSource = ''
>>** do your delete code and pack **
>>ThisForm.myGrid.RecordSource = 'tableA'
>>
>>
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform