Spread Silverlight Documentation
Adding a Component to the Project
Spread Silverlight Documentation > Developer's Guide > Getting Started > Adding a Component to the Project

If you are new to the Silverlight platform, you might be unfamiliar with how to start a new project using a component. To use the Spread Silverlight product, you need to add the component to a project in Visual Studio.

The first step is to create a new project in Visual Studio, and to add a Spread Silverlight component to the project.

  1. Start Visual Studio.
  2. From the File menu, choose New, Project.
  3. In the New Project dialog, select a project type depending on the language environment in which you are developing.
  4. Select Silverlight under Visual Basic or Visual C# in the Installed Templates section.
  5. Choose Silverlight Application in the project type area.
  6. In the Name box, type the name of the new project.
  7. In the Location box, type the path to save the project to.
  8. In the Solution Name box, type the solution name of the new project.
  9. Click OK.

The next step is to add the GcSpreadSheet component to the toolbox. This only has to be done once.

  1. If the Toolbox is not displayed, from the View menu choose Toolbox.
  2. Once the Toolbox is displayed, look in the ComponentOne Spread category (or in any other category if you have installed Spread and placed the toolbox icon in a different category).

  3. If the GcSpread component is not in the Toolbox, right-click in the Toolbox, and from the pop-up menu select Choose Items.
  4. In the Customize Toolbox dialog, click the Silverlight Components tab.
  5. In the Silverlight Components tab, the GcSpreadSheet component (in the GrapeCity.Silverlight.SpreadSheet.UI namespace) should be displayed in the list of components. Select the GcSpreadSheet component check box and click OK.

    If the GcSpreadSheet component is not displayed in the list of components, click Browse and browse to the installation path for the Spread Silverlight component. Once there, select the GrapeCity.Silverlight.SpreadSheet.UI.dll and click Open. The GcSpreadSheet component is now displayed in the list of components.

  6. You can test that the component has been added by opening a project and inserting the component.

The next step is to add the GcSpreadSheet component to a project.

  1. With an open project, in the Toolbox, select the GcSpreadSheet component.
  2. On your Main Window page, draw a GcSpreadSheet component by dragging a rectangle the size that you would like the initial component or simply double-click on the page.The GcSpreadSheet component appears.