Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Updating a scrolling panel.

Status
Not open for further replies.

tomcoombs

Programmer
Aug 14, 2003
65
GB
Hello All,

I have made, in effect my own ListView control. (As no ownerdraw mode of it in c#, do not get me started :) )

Anyway, all works very well until many "rows" are added. A "row" is a row usercontrol being added to a scrolling panel.

When many rows are in and you scroll to the bottem, it redraws ALL rows from the top. (If 1000 rows, it takes for ever!!!) How can I get it only to update the VIEWED area of the panel.

Or is there another solution..?


Thanks

Tom
 
I'm having a hard time visualizing your problem. Are you saying that it is repainting the usercontrols when they aren't visible in the scrolling panel? Or is it just performing operations on the usercontrols that aren't visible (and thus eating up unnecessary CPU time)?

If my second question is the case, then I would think that you could check each usercontrol's "Visible" property and not perform any operations on it if the value is 'false'.

If this isn't what you're looking for, please clarify.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top