setValue

setValue(controlName: String;
         memberName:  String;
         paramList:   ParamListType);

The setValue method of the JadeXamlControl class sets the value of a WPF property for an entity of a XAML control

The parameters are combined to form a sequence of accesses to the WPF entities involved. The JADE method parameters are a mixture of property names, method names, and WPF method parameters, with the last parameter containing the primitive value to be set. as described in the following table.

Parameter Description
controlName Name of the WPF FrameworkElement involved. If the name is null or equal to the control name, the search for the memberName starts with the parent control; otherwise the search starts with the first child element with the specified name. The search succeeds when the entity or one of its children is found to have the specified memberName value. An exception is raised if the controlName or memberName is not found.
memberName Name of the first method or property being accessed.
paramList Remaining property, methods, and parameters used in sequence. The final parameter is the value being set.

The code fragments in the following examples show how these parameters are used.

jadeXamlCtl.setValue("list", "SelectedIndex", 3);
     // sets the integer value of the currently selected item of the
     // list box entity named "list" to 3 by executing the WPF sequence
     // list.SelectedIndex = 3.

jadeXamlCtl.setValue("list", "SelectedItem", "Content", "new text");
     // sets the content of the currently selected item of the list box
     // to "new text" by executing the WPF sequence
     // list.SelectedItem.Content = "new text"

jadeXamlCtl.setValue("list", "Items", "GetItemAt", 3, "Content", "Customer")
     // sets the content of the list box entry with an index of 3 to
     // "Customer", by executing the WPF sequence
     // list.Items.GetItemAt(3).Contents= "Customer"

Note the following restrictions.