Lesson 10: Group Variables Into Dialogs

Overview

This lesson teaches you how to group related variables together in dialogs.

As you learned in the last lesson when you test assembled your template, HotDocs automatically creates a default dialog (or a question window) for each variable. When the user assembles the document, HotDocs presents each of these individual dialogs in the order the variables are used in the template.

However, if you want to have more control over the information-gathering process, you can create custom dialogs. To do this, you group related questions together and add text (and other design elements) to the dialog to help the user provide correct answers. You can also control the order in which custom dialogs appear during the interview.

When you add a variable to a dialog, HotDocs creates a link between the variable and the dialog. When an answer is needed for the variable during the interview, HotDocs displays the linked dialog instead of displaying the variable by itself.

When HotDocs assembles a document that contains variables, it reads through the document much like you would—it reads, line by line, all of the text in the template, starting at the top left corner and finishing at the bottom-right corner. As HotDocs encounters variable fields, it checks for two things—1) if the variable has been asked, and 2) if the variable is linked to a dialog. If the variable has already been asked, HotDocs skips it and moves to the next variable or instruction in the template. However, if the variable has not been asked, HotDocs checks to see if it has been included in a dialog. If it has, HotDocs presents the dialog to the user so he or she can answer the questions in it. If the variable is not linked to a custom dialog, HotDocs asks the variable in its own default dialog.

Start the Tutorial

If you are continuing immediately from Lesson 9, skip the instructions for opening the template and proceed to Create the First Custom Dialog.

If you closed the template at the end of Lesson 9, complete the following steps.

To open the tutorial template

  1. Open your word processor and click the hotdocs00224.jpgHotDocs button, located on your word processor’s toolbar. The My Test Templates library appears.

    If the My Test Templates library does not appear, choose Open Library (File menu), select the library in the default Libraries folder (for example, My Test Templates.hdl), and click Open.

  2. Select Employment Agreement and click edittemplate00227.jpgEdit. The template appears, ready for you to edit.

Create the First Custom Dialog

How you group variables into dialogs depends on the template and your own pref­erences. Generally, you begin with the most basic information. In the Employment Agreement, the most basic information pertains to the employee.

To create a custom dialog, you use Component Manager. Component Manager is a tool that lets you work with the different components and properties you use in your template. (These are stored in the component file, which you learned about when you created the new template in Lesson 3.)

To create a dialog

  1. At the template, click the componentmanager00554.jpgComponent Manager button. Component Manager appears.
    inset_9900557.png

    You can arrange both the Component Manager and word processor window so that you can view both windows simultaneously. To do this, adjust Component Manager to the desired width and click the arrange00560.jpgArrange Windows button.

    Component Manager lists all of the components associated with the template. It also provides several tools for working with the components. Using Compo­nent Manager you can create new components—specifically dialogs.

  2. Click the Components drop-down button and select Dialogs from the list. The component list is filtered to show only dialogs. (You have not yet created any dialogs, so this list is empty.)
    inset_10000563.png
  3. Click the newcomponent00566.jpgNew Component button. The Dialog Editor appears.
    inset_10100569.png
  4. Type Employee Information in the Dialog name box.
    inset_10200572.png

     

Add Variables to the Dialog

The next step is adding the employee variables to the dialog.

To add variables to a dialog

  1. In the Components list, click on Employee Name and drag it to the Contents box.
    inset_10300575.png
  2. Drag Employee Gender from the Components list to the Contents box.
    inset_10400578.png
  3. Click Test. A test assembly window appears.
    inset_10500581.png

    The dialog looks the way it will when it is displayed during the interview.

  4. Close the test assembly window, and then click OK at the Dialog Editor. The dialog Employee Information is now complete.

Create the Second Dialog

The second dialog you will create will ask the questions about the agreement.

To create the dialog

  1. At Component Manager, click the newcomponent00584.jpgNew Component button. The Dialog Editor appears.
  2. Enter Agreement Information in the Dialog name box.

    Components you have already added to a dialog are sorted to the bottom of the Components list and appear grayed. This helps you know they have already been included in a dialog.

  3. Drag the following variables from the Components list to the Contents list, in this order:

    Agreement Date

    Company Representative

    Signature Date

    inset_10600587.png
  4. Click OK. The Dialog Editor is closed.

On Your Own

Create the next two dialogs, based on the following information:

Dialog Name Components
Job Information Job Title Job Description Start Date Employee to Complete Trial Period Employee to Receive Paid Seminar Days Number of Seminar Days
Salary and Benefits Employment Status Exempt Annual Salary Hourly Salary Number of Vacation Days

Make sure you add the variables in the order they are listed in the table.

Group True/False Variables in a Dialog

When you view a dialog that contains True/False variables, they appear as Yes/No questions, like this:

true-false-yes-no.jpg

You can select an option that makes these variables appear as check boxes (allowing the user to select multiple answers) or as option buttons (allowing the user to select just one answer). You do this by assigning a selection grouping to the dialog.

To group True/False variables

  1. At Component Manager, select the Job Information dialog and click the edit00592.jpgEdit Component button. The Dialog Editor appears.
    inset_10700595.png
  2. Click Test. The test assembly window appears.
    inset_10800598.png

    Notice the two True/False variables in the dialog appear as Yes/No questions.

  3. In the interview outline, click on the Job Information dialog icon and click the edit00601.jpgEdit Component button. The Dialog Editor comes to the front.
  4. Click the Options tab.
    inset_10900604.png
  5. Click the Selection grouping drop-down button and choose Select All That Apply.
    inset_11000607.png
  6. Click Update. The test assembly window appears again and shows the updated dialog. Note how the two True/False variables now appear as check boxes.
    inset_11100610.png

Visually Separate Items in a Dialog

As you review the Job Information dialog, you may notice that you’d like to separate the seminar attendance questions from the rest of the variables in the dialog. You can do this by creating a dialog space element. You can create a single dialog element and use it in any number of dialogs.

To create a dialog element

  1. Bring the Dialog Editor to the front. (To do this, click on the dialog icon in the interview outline and then click the edit00613.jpgEdit Component button.)
    inset_11200616.png
  2. Click the Properties tab.

    You can use dialog elements to include other items in a dialog, such as additional text, horizontal lines, or buttons that calcu­late values or launch the Web browser, just to name a few.

  3. Click the dialogelement.jpgCreate New Dialog Element button and drag it to the Contents list, dropping it between the two True/False variables.
    inset_11300621.png

    The Dialog Element Editor appears.

    inset_11400624.png
  4. In the Dialog element name box, enter the text White Space.
  5. In the Style group, select Vertical spacing.
  6. Click OK. You are returned to the Dialog Editor.
  7. Click Update. The test assembly window appears again, showing the updated dialog. Note the extra space between the Trial Period and Paid Seminar Days questions.
  8. Close the test assembly window and click OK at the Dialog Editor.

On Your Own

Although you already added the White Space dialog element to the previous dialog, it is not grayed in the Components list. This is because dialog elements can appear on multiple dialogs, or even multiple times on the same dialog.

Edit the Salary and Benefits dialog, and add the White Space dialog element you created in the previous section to it. To do this, drag the element from the Compo­nents list and drop it between the variables Hourly Salary and Number of Vacation Days. Close the Dialog Editor when you are finished.

Conclusion

You are now finished with this lesson. In it, you learned how to group variables into dialogs. You also learned how to group True/False variables in a dialog so they appear as option buttons or check boxes.

If you do not want to go on to Lesson 11 at this time, close Component Manager by clicking the X in the upper-right corner of Component Manager. Then click the HotDocs close00638.jpgSave and Close button to close the template. Then exit HotDocs.

If you are continuing on to Lesson 11, click the save00641.jpgSave button to save your work.