9.2 Creating a Form

Developers can create forms using a number of wizards including the Create Application Wizard, Create Page Wizard, and Create Region Wizard. Note that the available forms differ depending the selected application user interface (for example, Desktop or Mobile).

Tip:

In some wizards you select the table and in others you provide the SQL query. For assistance in writing the SQL query, click the Query Builder button. See "Using Query Builder" in Oracle Application Express SQL Workshop Guide.

Topics:

9.2.1 Form Options When Running the Create Page Wizard

When you create an application, you choose a target user interface. The user interface you select determines the available forms.

Available Forms for Desktop Applications

If you are creating a desktop application, the Create Page Wizard supports the following forms.

Table 9-1 Create Page Wizard — Forms for Desktop Applications

Form Type Description To Learn More

Report with Form on Table

Creates two pages. One page displays as an interactive grid. Each row provides a link to the second page to enable users to update each record. You can select the table on which to build the report and form.

Note: This wizard does not support tables having more than 127 columns. Selecting more than 127 columns generates an error.

Not applicable.

Editable Interactive Grid

An interactive grid presents users a set of data in a searchable, customizable report. In an editable interactive grid, users can also add to, modify, and refresh the data set directly on the page. Functionally, an interactive grid includes most customization capabilities available in interactive reports plus the ability to rearrange the report interactively using the mouse. You choose a table on which to build the interactive grid.

See "Managing Interactive Grids"and "Making an Existing Interactive Grid Editable"

Single Page Master Detail

Creates single page master detail with editable interactive grids. With this page, users can query, insert, update, and delete values from two tables or views which are related. You choose the tables on which to build the master and detail regions.

See "Managing Master Detail Forms"

Two Page Master Detail

A two page master detail creates one interactive grid on the first page for the master table and on the second page it creates a standard form (for the master) and interactive grid for the detail.

See "Managing Master Detail Forms"

Form on a Table

Creates a form that enables users to update a single row in a database table. You can choose a table on which to build a form.

Not applicable.

Form on a Procedure

Builds a form based on stored procedure arguments. Use this approach when you have implemented logic or Data Manipulation Language (DML) in a stored procedure or package.

Not applicable.

Form on a SQL Query

Creates a form based on the columns returned by a SQL query such as an EQUIJOIN.

Not applicable.

Form on Web Service

Creates a page with items based on a Web service definition. This wizard creates a user input form, a process to call the Web service, and a submit button.

See "Creating a Form on a Web Service"

Report and Form on Web Service

Creates a page with items based on a Web service definition. This wizard creates a user input form, a process to call the Web service, a submit button, and displays the results returned in a report.

See "Creating an Input Form and Report on a Web Service"

Available Forms for Mobile Applications

If you are creating a mobile application, the Create Page Wizard supports the following forms.

Table 9-2 Create Page Wizard — Forms for Mobile Applications

Form Type Description To Learn More

Report with a List View on Table

Creates a form and list view that enables users to update a single row in a database table. You choose the table on which to build the form and select the column to be used for displaying text in the List View.

Not applicable

Form on a Table

Creates a form that enables users to update a single row in a database table. You can choose a table on which to build a form.

Not applicable

Form on a Procedure

Builds a form based on stored procedure arguments. Use this approach when you have implemented logic or Data Manipulation Language (DML) in a stored procedure or package.

Not applicable

Form on a SQL Query

Creates a form based on the columns returned by a SQL query such as an EQUIJOIN.

Not applicable

Form on Web Service

Creates a page with items based on a Web service definition. This wizard creates a user input form, a process to call the Web service, and a submit button.

See "Creating a Form on a Web Service"

Report and Form on Web Service

Creates a page with items based on a Web service definition. This wizard creates a user input form, a process to call the Web service, a submit button, and displays the results returned in a report.

See "Creating an Input Form and Report on a Web Service"

9.2.2 Creating a Form Using the Create Page Wizard

The easiest way to create a form is to use the Create Page Wizard.

To create a form using the Create Page Wizard:

  1. On the Workspace home page, click the App Builder icon.
  2. Select an application.
  3. Click Create Page.
  4. For Create a Page:
    1. User Interface - Select a user interface for the page.
    2. Select a page type - Select Form.
    3. Click Next.
  5. Select the type of form page you wish to create. See "Form Options When Running the Create Page Wizard."
  6. Follow the on-screen instructions.
    To learn more about an attribute, see field-level Help.

9.2.3 Creating a Form Using the Create Application Wizard

Use the Create Application Wizard to create a form to update a single row in a table. This wizard enables you to choose the table on which to build the form.

To create a form using the Create Application Wizard:

  1. On the Workspace home page, click the App Builder icon.
  2. Click the Create button.
  3. For the application type, select Desktop and click Next.
  4. For Name:
    1. Schema - Each application obtains its privileges by parsing all SQL as a specific database schema. Identify the database schema owner.
    2. Name - Enter the name used to identify the application to developers.
    3. Application - Specify an integer value that identifies the application. The application ID must be unique within your Application Express instance. Application IDs between 3000 to 9000 are reserved for internal use by Oracle Application Express.
    4. Theme - Select a theme. Themes are collections of templates used to define the layout and style of an entire application.
    5. Theme Style - Select a theme style. Theme styles are only available for newer applications such as theme 42 and 51.
      A theme style is a CSS that is added to the base CSS. Using the Theme Roller utility, developers can change the appearance of an application.
    6. Click Next.

    Tip:

    To create an application at this point that consists of just a login page and a blank page, click Create Application.

    Next, add pages to your application.

  5. For Pages, click Add Page. In Create Application dialog:
    1. Select Page Type - Select the page type Form.
    2. Parent Page - If applicable, select a subordinate page. To learn more about an attribute, see field-level Help.
    3. Table Name - Select a table.
    4. Click Add Page.
    The page (or pages) appear at the top of the page. To delete a page, click the Delete icon.
  6. Repeat the previous steps until all pages have been added.
  7. Click Next.
  8. Follow the on-screen instructions.

    Tip:

    To learn more about an attribute, see field-level Help.

9.2.4 Creating a Form Region in Page Designer

Note:

You can also create a form manually by selecting it in the Gallery and dragging and dropping it in the Layout tab. However, Oracle does not recommend a manual approach when creating forms since it does not create all the necessary underlying form items and processes.

To create a form in Page Designer:

  1. View the page in Page Designer:
    1. On the Workspace home page, click the App Builder icon.
    2. Select an application.
    3. Select a page.
    Page Designer appears.
  2. Locate the Page Designer Toolbar at the top of the page.
  3. On Page Designer Toolbar, click the Create menu and select Form Region.

    The Create Region Wizard appears.

  4. Select the type of form you wish to create and click Next.
    Options include:
    • Form on a Table

    • Form on a SQL Query

    • Form on a Procedure

    • Form on a Web Service

    To learn more about form region options, see "Region Types When Running the Create Region Wizard."

  5. Follow the on-screen instructions.