Building and Previewing

When you have authored your documentation, you will want to build it. You might also want to see how it looks in the Mathematica help system. This can be done conveniently with the Application Tools.

The Application Tools can be opened from the menu bar, by selecting Window > Show View > Application Tools. (If you are not in the Mathematica perspective you need to select Window > Show View > Other and look in the Wolfram section.) The Application Tools are shown below.

You can use the tools as described in the following.

Select a Project

You must first select the project you wish to work with; if you do not do this the Workbench will remind you. Click on the drop-down menu and you will see a list of projects; select the one you wish to work with.

Run a Build

Now you can click the Run Build button: this will launch Mathematica and build all the source notebooks in your project. A report on the progress is shown in the console view.

The results are placed into your project in a folder called build. A sample is shown below.

The build folder contains the notebooks that can be used in the Mathematica documentation system.

The documentation build is actually scripted by a file called docbuild.xml which is found at the root of the project. This is created automatically if it does not exist. If you want to use a file with a different name or location you can do this by setting the documentation build file project property.

Preview the Documentation

When the build has finished you can preview the result by clicking the Preview button. This will launch Mathematica, open the help system, and automatically enter the name of your application in the search field. This should open the main page for the application. An example is shown below.

In this example the application is called NumericalAnalysis and the main page is found when you enter NumericalAnalysis into the Mathematica help system. If it does not find your application, then you probably have not set a root guide page. You can still find your documentation by going to the Mathematica documentation home page and clicking on the Installed Add-Ons. Your documentation should show up here, as shown below.

HTML Documentation

The documentation building tools can also create an HTML version of your documentation that you can use on a web site. To create HTML you should check the Create HTML box in the Application Tools and carry out a documentation build. The HTML will be created in the build folder.