We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Optimizing render speed when applying style changes to elements

Thread ID:

Created:

Updated:

Platform:

Replies:

24255 Jan 31,2005 10:05 AM Feb 4,2005 11:50 AM Windows Forms 2
loading
Tags: HTMLUIControl
Adam Flynn
Asked On January 31, 2005 10:05 AM

When changing the class of an element in order to change its css display style, what is the best way to ensure good performance. Example 1: htmlUiControl.SuspendLayout(); element.Attributes["class"].Value = cssClassName; htmluiControlMain.PerformLayout(); Example 2: htmlUiControl.BeginUpdate(); element.Attributes["class"].Value = cssClassName; htmluiControlMain.EndUpdate(); If neither of these sequences are correct, do you recommend another method?

Davis Jebaraj [Syncfusion]
Replied On February 1, 2005 08:02 AM

Hi, If you are making multiple attribute changes, you can call the BeginUpdate / EndUpdate methods. The HTMLUIControl will not update its interface till the EndUpdate method is called. Regards, Davis

Davis Jebaraj [Syncfusion]
Replied On February 4, 2005 11:50 AM

Hi Adam, I just realized that you can optimize the style changes by setting the htmluiControl1.Document.BeginUpdate(); and htmluiControl1.Document.EndUpdate(); We can change the behavior so that the BeginUpdate and EndUpdate methods of the HTMLUIControl also have the same effect. Thanks, Davis

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;