Sun Java Studio Creator 2 Update 1 – Online Help
 

Working With Web Applications

The following table shows general steps for developing a web application.

Number one
Create project

new project icon

  1. From the main menu, choose File > New Project or, in the Welcome window, click Create New Project.
     
  2. Step through the wizard.
     

Number two
Add components

palette icon

  1. Drag components from the Palette to the Visual Designer.
     
  2. Using the Properties window, set the component properties.
     

Number three
(Optional)
Connect to data source

data source node icon

  1. If the data source is not in the Servers window, add the data source.
     
  2. Drag a table from the data source to the Visual Designer.
     
  3. If desired, create a customized query by double clicking table-nameRowSet in the Outline window to use the Query Editor.
     
  4. In the Query Editor, create the SQL query.
     
  5. In the Visual Designer, right-click the component and choose Bind to Data.
     
  6. In the Bind Data dialog box, choose the data provider and data field to bind to the component.
     

Number four
(Optional)
Connect to web service

web services node icon

  1. In the Servers window, right-click the Web Services node and choose Add Web Service.
     
  2. Specify the location of the WDSL file, by either entering the URL or finding the file on your filesystem.
     
  3. If you enter a URL and you are behind a firewall, click Set HTTP Proxy to set your HTTP proxy.
     
  4. In the Servers window, drag the web service and drop it on to the page.
     
  5. To view the data produced by the method, bind the simple, list or Table component to the method or call the method in your Java code.
     

Number five
(Optional)
Connect to Enterprise JavaBean method

Enterprise JavaBean icon

  1. In the Servers window, right-click the Enterprise JavaBeans node and choose Add Set of Session EJBs.
     
  2. In the Servers window, drag the enterprise bean or one of its methods and drop it on to the page.
     
  3. To view the data produced by the method, bind the simple, list or Table component to the method or call the method in your Java code.
     

Number six
Program business logic

Java code page icon

  1. In Visual Design view in the Visual Designer, double-click the background of the page to open the Java Editor.
     
  2. In the Java Editor, edit the code.
     

Number seven
Create and connect multiple pages

navigation editor icon

  1. In the Visual Designer, right-click and choose Page Navigation.
     
  2. In the Navigation Editor, right-click and choose New Page to create the destination page.
     
  3. In the Navigation Editor, click the source page to display its components.
     
  4. In the source page, click the component that triggers the navigation and drag the connector to the destination page.
     

Number eight
Deploy and debug application

run project icon

  1. Choose Run > Run Main Project to save, build, and run the application.
     
  2. If you need to debug the application, choose Run > Debug Main Project.
     
 
 
 
Legal Notices. Copyright © 2006 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Close