Add Controls for Input and Output

You can add graphical user interface (GUI) controls to a form using the Controls Toolbar in the Editor pane.

To add the controls
  1. Open your project in Presentation Designer, select a form, and click the Customize tab.

  2. Create a button to trigger the event that accesses the Web service.

    1. From the Controls Toolbar on the left side of the Editor, choose the button control by clicking it.

      Positioning your mouse cursor over the toolbar will activate tooltips to help you identify the controls.

    2. Move the cursor to the form (the cursor changes to a cross-hair), then click the mouse on the form where you want to place the button.

    3. Reposition or resize the button as necessary to suit your particular needs.

    4. Change the button's caption to "Submit." Select the button, and then in the Properties Editor, in the lower left of the Presentation Designer window, double-click the value field next to Caption. Caption is under the Format tab.

  3. Create a text field for the data to send to the Web service.

    This field will allow the end user to type a zip code to send to the Web service, to get weather information for a specific area.

    1. From the Controls Toolbar on the left side of the Editor, click the text field control.

    2. Move the cursor to the form (the cursor changes to a cross-hair), then click the mouse on the form where you want to place the text field.

    3. Change the text field's name to "Zipcode." Select the text field, and then in the Properties Editor, in the lower left of the Presentation Designer window, double-click the value field next to Name. Name is under the Data tab.

  4. Create a text field to display the data received from the Web service.

    This field will show the average temperature at the zip code specified. More fields could be added if the Web service has more types of output.

    1. From the Controls Toolbar on the left side of the Editor, click the text field control.

    2. Move the cursor to the form (the cursor changes to a cross-hair), then click the mouse on the form where you want to place the text field.

    3. Change the text field's name to "Temperature." Select the text field, and then in the Properties Editor, in the lower left of the Presentation Designer window, double-click the value field next to Name. Name is under the Data tab.

  Attachmate