![]() |
How to delete a report row |
Post Reply
|
| Author | |
garylyb
Newbie
Joined: 23 August 2006 Status: Offline Points: 17 |
Post Options
Thanks(0)
Quote Reply
Topic: How to delete a report rowPosted: 12 April 2008 at 7:38pm |
|
I have this code to delete any rows that are checked: // Now see if any rows need to be deleted CXTPReportRows *pRows = m_wndReportCtrl.GetRows(); for ( int j=0 ; j < pRows->GetCount() ; j++ ) { CXTPReportRow *pRow = pRows->GetAt(j); BOOL bChecked = pRow->GetRecord()->GetItem(COLUMN_DELETE)->IsChecked(); if ( bChecked ) { pRows->RemoveAt(j); } } m_wndReportCtrl.RedrawControl(); It works, but when I click on the header to sort the report, the deleted rows come back, still checked. How can I get rid of it for good? |
|
![]() |
|
Michl
Senior Member
Joined: 14 September 2007 Status: Offline Points: 138 |
Post Options
Thanks(0)
Quote Reply
Posted: 15 April 2008 at 4:39am |
|
RedrawControl() is not enough. You must recall Populate().
|
|
![]() |
|
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 |