Wrox Programmer Forums
Go Back   Wrox Programmer Forums > C# and C > C# 2005 > C# 2005
|
C# 2005 For discussion of Visual C# 2005.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the C# 2005 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 20th, 2008, 08:54 PM
Authorized User
 
Join Date: Aug 2007
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default Relod dataGridview thousands of time in minute

i am doing networking project in that i have taken Datagridview to show that from which server to client how many packets are going?if i detect 1st packet from server "yahoo" to "Local Machine" i will make a entry for that,after that if i detect other packet from same server to same client i will update to packet column to 2.now like this hundreds are packets are coming to same server to same machine,so for showing current situation to user i have to reload a data grid view hundreds of time in minute ,this cause a screen flickering in area of data grid ,i want to know that can i load a particular cell only,so don't neet to whole data grid view,or ,is any other way to stop this flickering,thanking you in advance.

 
Old April 21st, 2008, 12:27 AM
Friend of Wrox
 
Join Date: Mar 2007
Posts: 432
Thanks: 0
Thanked 1 Time in 1 Post
Default

Hi Theone,

Forcing that many repaints is going to be quite expensive. Would it not be a better idea to save the data for the list, but only refresh the DataGrid once every second or something? (ideally you would want to specify the frequency).

Rob
http://robzyc.spaces.live.com
 
Old April 21st, 2008, 04:23 AM
samjudson's Avatar
Friend of Wrox
 
Join Date: Aug 2007
Posts: 2,128
Thanks: 1
Thanked 189 Times in 188 Posts
Default

Reloading a DataGridView (or any control on a form) thousands of times a second is not only likely to create an epilepsy inducing screen flicker but likely bring most PCs to a grinding halt.

Like Rob says, storing up the changes and refreshing the grid every second (or even longer) would be a much better way to go.

/- Sam Judson : Wrox Technical Editor -/





Similar Threads
Thread Thread Starter Forum Replies Last Post
job schedule every minute for a stored procedure dfgilto SQL Server 2005 1 February 7th, 2008 07:30 PM
Thousands and Decimals - Notation fskilnik Dreamweaver (all versions) 3 October 4th, 2005 02:35 PM
sprintf and thousands separators motoman711 Beginning PHP 1 April 5th, 2005 04:00 PM
setTimeout second to Minute mateenmohd Javascript 6 November 28th, 2004 02:12 AM
thousands records enter one table to another table mateenmohd SQL Server 2000 3 July 17th, 2003 07:52 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.