Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

VisualStyleRenderer.SetParameters Method (String, Int32, Int32)

Sets this VisualStyleRenderer to the visual style element represented by the specified class, part, and state values.

Namespace:  System.Windows.Forms.VisualStyles
Assembly:  System.Windows.Forms (in System.Windows.Forms.dll)

public void SetParameters(
	string className,
	int part,
	int state


Type: System.String

The new value of the Class property.

Type: System.Int32

The new value of the Part property.

Type: System.Int32

The new value of the State property.


The combination of className, part, and state is not defined by the current visual style.


The operating system does not support visual styles.


Visual styles are disabled by the user in the operating system.


Visual styles are not applied to the client area of application windows.

This method checks the value of the IsSupported property internally. Before calling this method, you should call the IsElementDefined method to verify that the current visual style provides a definition for the element specified by the className, part, and state parameters.

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5, 3.0, 2.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1
© 2015 Microsoft