Sets this System.Windows.Forms.VisualStyles.VisualStyleRenderer to the visual style element represented by the specified class, part, and state values.
- className
- The new value of the VisualStyleRenderer.Class property.
- part
- The new value of the VisualStyleRenderer.Part property.
- state
- The new value of the VisualStyleRenderer.State property.
This method checks the value of the VisualStyleRenderer.IsSupported property internally. Before calling this method, you should call the VisualStyleRenderer.IsElementDefined(VisualStyleElement) method to verify that the current visual style provides a definition for the element specified by the className, part, and state parameters.