Export (0) Print
Expand All

Set a startup document for your project

This page applies to WPF projects only

In a Windows Presentation Foundation (WPF) project, the startup document is the XAML document that will run first when you test or run your compiled application. While creating your project, you might change the startup document in order to quickly test individual documents. Before publishing your application, remember to set the startup document to your final choice.

Cc295103.alert_note(en-us,Expression.30).gifNote:

You can set only a Window, Page, or UserControl item as the startup document in a project—you cannot set a resource dictionary or a user control (.dll) as the startup document.

  1. In the Projects panel, right-click the document that you want to run first when your application is run, and then click Startup. Alternatively, you can select the startup document by using the Set As Startup command on the Project menu.

  2. On the Project menu, click Run Project, or press F5.

  3. In the Results panel, review the test build process for any errors that may have been returned.

    If the test build is successful, your startup document will automatically open in an application window. If you encounter an error, you will have to repair the error before you can successfully build the project.

    For more information, see Debug Expression Blend applications.

    Cc295103.alert_tip(en-us,Expression.30).gifTip:

    The startup document is specified in the app.xaml file for the project. If you project is under source control, remember to check in the app.xaml file after you change your startup document.

    For more information, see Check files in and out.

Community Additions

ADD
Show:
© 2014 Microsoft