Reflector (Silverlight Only) > Task-Based Help > Adding a Control to the Reflector |
The C1Reflector control can accept Silverlight UI controls. To illustrate this feature, this topic will have you add a standard Silverlight Button to the reflector. Once it is added to the control, you will see the control and its reflection in the C1Reflector control.
At Design Time in Blend
To add a control, complete the following steps:
In XAML
To add a control, place the following markup between the <c1ext:C1Reflector> and </c1ext:C1Reflector> tags:
XAML |
Copy Code
|
---|---|
<Button Content="Button"></Button>
|
In Code
To add a control, complete the following steps:
Visual Basic Copy Code 'Create a button object and name it Dim Button1 As New Button() Button1.Content = "Button" 'Set the C1Reflector control's content to the button C1Reflector1.Content = Button1
C# Copy Code //Create a button object and name it Button Button1 = new Button(); Button1.Content = "Button"; //Set the C1Reflector control's content to the button C1Reflector1.Content = Button1;
This Topic Illustrates the Following:
The result of this topic will resemble the following image: