In this step you will create a new project and add a reference to the C1.Xaml.Excel assembly.
- Create a new Windows Store project. When the project opens, double-click the MainPage.xaml file to open it.
- Right-click References in the Solution Explorer and select Add Reference from the list.
- Browse to find C1.Xaml.Excel.dll.
- Click OK to add the assembly reference to your application.
- In XAML View, place your cursor between the <Grid> </Grid> tags.
- Add two standard Button controls and one standard TextBox control to the page.
- Edit the markup for the first button so that it resembles the following:
Markup |
Copy Code
|
<Button x:Name="HelloButton" Content="Click Hello" />
|
- Edit the markup for the second button so that it resembles the following:
Markup |
Copy Code
|
<Button x:Name="SaveButton" Content="Save" />
|
- Edit the markup for the TextBox control so that it resembles the following:
Markup |
Copy Code
|
<TextBox
Name="_tbContent"
Text="Empty"
IsReadOnly="True"
AcceptsReturn="True"
FontFamily="Courier New"
Background="White" Margin="465,10,242,722" />
|
- Double-click the HelloButton to switch to the code view of MainPage.xaml. This will also add a HelloButton_Click event to the code.
- Switch back to Design View and double-click the SaveButton to add a SaveButton_Click event to the code.
- Add the using (C#) statement to the code at the top of the form so you can use all names within the C1.Xaml.Excel namespace.
C# |
Copy Code
|
using C1.Xaml.Excel;
|
Now you can add some content to a C1XLBook.
See Also