42.2 Create a Parameter Form in HTML

The steps in this section will show you how to build a simple Parameter Form using plain HTML. You will then modify this HTML Parameter Form in Reports Builder so that you can call the Parameter Form from your JSP-based Web report.

If you do not want to create your own HTML file, you can open the sample HTML file we have provided in the Source directory, called paramform.html, then view the source code.

To create a simple Parameter Form in HTML:

  1. In a text editor or HTML editor, create an HTML page that contains a form. The form should contain a list of values, a field, and a button. The code for this form can look something like the following:

    <form name="form1" method="post" action="">
        <h2>Parameter Form</h2>
        <p>Choose a department from the list, then click the <b>Run Report</b>
    button to show salary details for each employee in that department.</p>
        <select name="p_department" size="1">
          <option value="1">a</option>
        <input type="text" name="userid" value="hr/hr@db-connect">
        <input type="submit" name="Submit" value="Run Report">


    Although you can use the above code, you will need to change the userid value to reflect the connection information for your data source. You can also copy and paste the HTML code from the provided file, called simplejsppf_code.txt in the simplejsppf/scripts directory, then modify it in a text or HTML editor.
  2. Save the HTML file as paramform_your_initials.html. When you display this HTML file in a Web browser, it should look similar to the following image:

    Figure 42-3 Sample HTML Parameter Form

    Description of Figure 42-3 follows
    Description of "Figure 42-3 Sample HTML Parameter Form"