Saturday, November 29, 2014

Forms.

Creation of sample 'form' step by step.


Step 1:Connecting forms 11g to database 11g.
  • Copy the file 'tnsnames.ora' from database folder to config folder in Oracle Middleware.
  • Go to the Oracle Form Builder, go to File Menu and press Connect or just execute the command Ctrl+J.
  • Finally you need to enter the user name, password and the database name.
Step 2: Changing Module Name in Oracle Forms.


In the object navigator select 'Modules' under forms and then click right button and select 'Property Pallet'. In the 'property palle't select name and enter your modulename'.

Step 3:Create New Data Block Wizard in Oracle Forms 11g.
  • Select  'Data Blocks' in the list and the press the button Create. Another window with two option will appear, and here you select ->Use the Data Block Wizard.
  • Another window with title 'Welcome to the Data Block Wizard!' - Click Next to begin creating your data block.
  • Select the type of Data Block: Table/View or Stored Procedure.
  • Click Browse button and will appear a small window with more choices: Tables, Views, Current user, Synonyms, Other users.
  • Once you select the table name, oracle forms will show all Available Columns from the table. Here you can bring all columns from the table in your form or you can select just a few or required columns.
  • After selecting the columns you can move the items to right panel and press Next.
  • It will ask for Name then Enter a name for your Data Block. Ex: Employee.
  • Now we are done with describing you data block. Now we will have two options: 
     1.Continue with: Call the Layout Wizard 
    2.Stop: Just create the data block(this is recommended when you use multiple data block on the same canvas)
Step 4:Create Layout Wizard Oracle Forms 11g.
  • Go to Layout wizard ->This wizard helps to easily layout the items of a data block.This wizard helps to display items in frame on a canvas and lay them in different styles.
  • Here we have to choose the canvas name(can be a new one or an existing canvas) and the type of canvas. 
    Below are the Types of canvas: 
    - Content 
    - Stacked 
    - Vertical Toolbar 
    - Horizontal Toolbar 
    - Tab.
Step 5 : How to Display available items.
  • After selecting the canvas type the next window will show the list of items to be displayed in canvas. select the required items and move them to 'Display items list'.
  • The next window  prompt for width and the height for each item. enter the desired dimensions.
  • Next step is to select the Layout Style for your frame.
            1.Form
            2.Tabular
           select 'Form' and click next.
  • Next step is  to choose the Frame Title, you can insert how many records to be displayed in the field 'Records Displayed', also Distance Between Records and Display Scroll bar.
  • You are done with creating layout frame.
  • Now go to 'Form'->Datablocks->Employee-> the tree will be displayed with list of items and on the right hand side newly created form will be displayed with list of items.


No comments: