473,386 Members | 1,796 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Data Binding Performance on forms containing many controls

Ron
Hi,

I have a Windows form which contains roughly 100 controls on multiple tabs.
I am data binding to a List<collection at runtime:
CompanyMasterData company = m_CompanyListCollection.Find((CompanyMasterData
co) =co.CompanyMasterDataID.Equals(companyID));
if (company == null)
{
company = new CompanyMasterData();
company.CompanyMasterDataID = Guid.NewGuid();
company.ChangeType = apx_CustomInterfaces.eDMLChange.Insert;
m_CompanyListCollection.Add(company);
}
CurrentCompany = company;
bindingSource.DataSource = CurrentCompany;

The problem is that the binding process is taking roughly 30 seconds. The
query is fast and takes less than a second it is strictly the binding that
is taking the remaining 29 seconds. I built a tracer and noticed that the
property mutator (SET) is getting hit 7 times each for each property in my
custom object. The first two times are Null values and occur within the
InitializeComponent code block. The remaining 5 times all hit the mutator
with the same value. I cant figure out why they are getting hit so many
times. It takes roughly 4 seconds to set the properties for all of the
controls...so multiply that times 7 and it takes 28 seconds to bind the
form.

Any suggestions on how I can improve the performance on this form?

Thanks,
Ron

Nov 14 '08 #1
0 1172

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Ann Morris | last post by:
INTRODUCTION One of the most powerful aspects of .NET and Windows Forms is data binding. Data binding is the process of associating user interface (UI) elements with a data source to generate a...
16
by: D Witherspoon | last post by:
I am developing a Windows Forms application in VB.NET that will use .NET remoting to access the data tier classes. A very simple way I have come up with is by creating typed (.xsd) datasets. For...
7
by: Andrew McKendrick | last post by:
Hi, I've noticed a bug in VB.NET (latest .NET Framework)... - I have a TabControl on a form with several tabs. - Each tab contains text boxes that are bound to fields in a data source...
19
by: Larry Lard | last post by:
In the old days (VB3 era), there was a thing called the Data Control, and you could use it to databind controls on forms to datasources, and so (as the marketing speak goes), 'create database...
0
by: mjsterz | last post by:
I've been working with VB .NET for less than a year and this is the first time I've posted on one of these groups, so let me apologize beforehand if I'm being unclear, not posting my issue...
14
by: Rolf Welskes | last post by:
Hello, I have an ObjectDataSource which has as business-object a simple array of strings. No problem. I have an own (custom) control to which I give the DataSourceId and in the custom-control...
5
by: raajakumars | last post by:
urgent!!!!!!! kindly please anyone help me....... actualy i am newbe to vb.net i need data to be inserted in to my table like this... sitenm cdate wrknm nowrk totwg tamiz palace...
2
by: John | last post by:
Hi I have a small app with bound controls that do not seem to be copying across the data entered into them to the underlying row for the update. This one really has me stump even though these...
6
by: Wesley Peace | last post by:
I hate to cross post, but I've gotten no answer yet on a problem I'm having with visual studio 2008. I've created a series of forms with controls to access a Access database tables. The...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.