Basic Library for WPF and Silverlight | ComponentOne
WPF and Silverlight Edition Basic Library / Menu and ContextMenu / Menu and ContextMenu Quick Start / Step 1 of 5: Creating a C1Menu Application
In This Topic
    Step 1 of 5: Creating a C1Menu Application
    In This Topic

    Complete the following steps:

    1. In Visual Studio, select File | New Project.
    2. In the New Project dialog box, select either Windows Desktop or Silverlight from the Templates in the left-hand pane.
    New Project Dialog Box

    New Project Dialog Box

    1.    
    2. Select Silverlight Application and enter a Name for your project, for example "QuickStart". Click OK. The New Silverlight Application dialog box will appear.
    3. Click OK to accept default settings. This will close the New Silverlight Application dialog box and create your project.
    4. The MainPage.xaml file should open.
    5. Add the following assemblies to your application by right-clicking the References folder and selecting Add Reference:
      • Silverlight: C1.Silverlight.5.dll
    1. Navigate to the Visual Studio Toolbox and add a C1Menu control by double-clicking.
    2. Edit the control's markup to add Height= "Auto" and Width= "Auto" to the <c1:C1Menu> tag. It should resemble the following:
    XAML
    Copy Code
    <c1:C1Menu HorizontalAlignment="Left" VerticalAlignment="Top" Height="Auto" Width="Auto"/>
    

    You have completed the first step of the Menu and ContextMenu for Silverlight quick start. In this step, you created a project and added a C1Menu control to it. In the next step, you will add top-level menu items to the control.