Documentation for: ASP.NET Ajax Version 1.0

This documentation is for a previous version. For the current released version, see the ASP.NET Ajax documentation on MSDN.

 

 

 

 

 

 

 

Sys.UI.Control toggleCssClass Method

Toggles a CSS class of the HTML Document Object Model (DOM) element that the control is attached to.

Syntax

var a = new Sys.UI.MyControl(domElementObj);
a.toggleCssClass(className);

Term

Definition

className

A string that contains the name of the CSS class to toggle.

Return Value

None.

Remarks

Use the toggleCssClass method to remove the CSS class from a control if the element contains the CSS class. If the element does not contain the CSS class, the toggleCssClass method adds the CSS class.