void SetPropertyObject( string name, System.Object value )

book_4_sparkGenerated
code_blocksInput

Description

The SetPropertyObject method is used to set a property on a Panel object. It first attempts to set the property directly on the panel object itself. If the property is not found, it processes any special properties such as class. This method is similar to SetProperty but allows for more complex object types as values.

Usage

To use the SetPropertyObject method, call it on an instance of a Panel and provide the property name as a string and the value as an object. This method is useful when you need to set properties that are not just simple strings, allowing for more flexibility in property assignment.

Example

// Example of using SetPropertyObject
Panel myPanel = new Panel();

// Set a property with a string value
myPanel.SetPropertyObject("color", "red");

// Set a property with an object value
myPanel.SetPropertyObject("data", new { Key = "value" });