![]() |
ReportCtrl... no method to remove items |
Post Reply
|
| Author | |
bevpet
Newbie
Joined: 01 April 2005 Location: Canada Status: Offline Points: 39 |
Post Options
Thanks(0)
Quote Reply
Topic: ReportCtrl... no method to remove itemsPosted: 04 May 2005 at 11:55am |
|
Hi. i'm trying to clear the contents of my report control after a call to myctrl.addrecord(...), i can't seem to find a method to clear the the items that were added. i need to clear the previous contents, so the display can be updated with current content. if anyone knows of the method to accomplish this, it would be greatly appreciated. thanks Peter
|
|
![]() |
|
sserge
Moderator Group
Joined: 01 December 2004 Status: Offline Points: 1297 |
Post Options
Thanks(0)
Quote Reply
Posted: 04 May 2005 at 3:28pm |
|
Hello Peter,
Try calling Populate() for updating. From the documentation: "As a finalization of adding data to the report control, which means adding columns and records, Populate() method should be called. It performs population of control rows with data - creates a rows tree if necessary, rebuilds groups if grouping if enabled, and sorts rows on a specified manner. " -- WBR, Serge |
|
![]() |
|
bevpet
Newbie
Joined: 01 April 2005 Location: Canada Status: Offline Points: 39 |
Post Options
Thanks(0)
Quote Reply
Posted: 04 May 2005 at 6:10pm |
|
Hi Serge, i've done that (called .populate()). My data is showing up fine, what the problem is that the reportctrl is refreshed every 15mins from my database, when it does, it duplicates the items on the report control, because i have no way of removing the previous items that were on it. i'm looking for a method on the control like on the standard list control's .DeleteAllItems() method, which removes all items from the list, thanks for your help Peter |
|
![]() |
|
walgar
Newbie
Joined: 13 February 2005 Status: Offline Points: 5 |
Post Options
Thanks(0)
Quote Reply
Posted: 04 May 2005 at 11:41pm |
|
Try: GetRecords()->RemoveAll() You can then add new records and call Populate(). Walgar.
|
|
![]() |
|
bevpet
Newbie
Joined: 01 April 2005 Location: Canada Status: Offline Points: 39 |
Post Options
Thanks(0)
Quote Reply
Posted: 05 May 2005 at 7:05pm |
|
Hi Walgar, that did the trick.
greatly appreciated, thanks Peter |
|
![]() |
|
Post Reply
|
|
|
Tweet
|
| Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |