ComponentOne Dialog for ASP.NET Web Forms
Quick Start / Step 1 of 3: Add C1Dialog to the Page
In This Topic
    Step 1 of 3: Add C1Dialog to the Page
    In This Topic

    In this step you'll create a new project and add a Dialog for ASP.NET Web Forms dialog window to your project. To begin the Quick Start, complete the following steps:

    1. From the Visual Studio File menu select New Project. The New Project dialog box will appear.
    2. In the New Project dialog box expand a language in the left-hand pane and select Web. In the right pane, choose ASP.NET Empty Web Application, enter a Name for your application, and select OK. A new application will be created.
    3. In the Solution Explorer, right-click the project and choose Add Reference.
    4. In the Add Reference dialog box, locate and select the C1.Web.Wijmo.Controls and C1.Web.Wijmo.Controls.Design assemblies and click OK. The references will be added.
    5. Right-click the project in the Solution Explorer and from the context menu choose Add │ New Item.
    6. In the Add New Item dialog box choose Web Form from the list of templates, name the item "Default.aspx", and click Add. The new page should open.
    7. While in Design view navigate to the Visual Studio Toolbox and double-click the Input (Button) and C1Dialog icons to add the Button and C1Dialog controls to your page.
    8. Select Button1, navigate to the Properties window, and set the Value property of the control to "Click Me!".
    9. In Source View add the onclick event handler to Button1so that control's markup looks like the following:

      To write code in Source View

      <input id="Button1" type="button" value="Click Me!"
                  onclick="$('#<%=c1dialog1.ClientID%>').c1dialog('open')"/>
      

      Now clicking on the Button will open the C1Dialog dialog window.

    You've completed creating a new project and adding a C1Dialog dialog window to your project. In the next step you'll customize the dialog window's appearance and behavior.