You are on page 1of 12

R11i Extend Oracle

Applications: Forms
Volume 1 Student Guide

14464GC11
Production 1.1
November 2000
M0-13456

Authors

Copyright Oracle Corporation, 2000. All rights reserved.

Martin Taylor

This documentation contains proprietary information of Oracle Corporation. It is


provided under a license agreement containing restrictions on use and disclosure
and is also protected by copyright law. Reverse engineering of the software is
prohibited. If this documentation is delivered to a U.S. Government Agency of the
Department of Defense, then it is delivered with Restricted Rights and the
following legend is applicable:

Mildred Wang
Sara Woodhull
Technical Contributors
and Reviewers

Phil Cannon
Anne Carlson
Steve Carter
Lisa Nordhagen
Mary Thomas
Peter Wallack
Publisher

Restricted Rights Legend


Use, duplication or disclosure by the Government is subject to restrictions for
commercial computer software and shall be deemed to be Restricted Rights
software under Federal law, as set forth in subparagraph (c)(1)(ii) of DFARS
252.227-7013, Rights in Technical Data and Computer Software (October 1988).
This material or any portion of it may not be copied in any form or by any means
without the express prior written permission of the Education Products group of
Oracle Corporation. Any other copying is a violation of copyright law and may
result in civil and/or criminal penalties.
If this documentation is delivered to a U.S. Government Agency not within the
Department of Defense, then it is delivered with Restricted Rights, as defined in
FAR 52.227-14, Rights in Data-General, including Alternate III (June 1987).
The information in this document is subject to change without notice. If you find
any problems in the documentation, please report them in writing to Worldwide
Education Services, Oracle Corporation, 500Oracle Parkway, Box SB-6,
Redwood Shores, CA 94065. Oracle Corporation does not warrant that this
document is error-free.
Oracle and all references to Oracle Products are trademarks or registered
trademarks of Oracle Corporation.
All other products or company names are used for identification purposes only,
and may be trademarks of their respective owners.

Table of Contents
Preface
Objectives ..................................................................................................................................................I-3
Before You Begin This Course ...............................................................................................................I-4
Prerequisites .............................................................................................................................................I-5
How This Course is Organized ..............................................................................................................I-6
Other Sources of Information .................................................................................................................I-7

1 Internet Computing Architecture


Objectives ..........................................................................................................................................1-3
Architecture Objectives with Internet Computing .....................................................................1-4
The Internet Computing Architecture ..........................................................................................1-5
The Oracle8i Database Server ........................................................................................................1-7
Choosing Your Development Platform(s) ...................................................................................1-8
Choosing Your Database Server Platform ...................................................................................1-9
Choosing Your Forms Server Platform ......................................................................................1-10
Choosing Your Developer Desktop Platform ............................................................................1-12
Or Develop on a Single Machine .................................................................................................1-15
The Form Development Process ..................................................................................................1-16
Building Your Form ......................................................................................................................1-17
Generating Your Form ..................................................................................................................1-19
Running Your Form for Testing ..................................................................................................1-20
Running Your Form on the Web .................................................................................................1-21
Deployment ....................................................................................................................................1-22

Extend Oracle Applications: Forms - Table of Contents

iii

2 Application Architecture
Objectives ..........................................................................................................................................2-3
Overview of Application Development .......................................................................................2-4
Overview of Form Development Steps .................................................................................2-5
Building an Application ..........................................................................................................2-6
Definitions .................................................................................................................................2-7
Getting Started on Your Application .....................................................................................2-8
Register Your Application .....................................................................................................2-10
Application Directory Structure ...........................................................................................2-12
Define Your Application Basepath ......................................................................................2-17
Overview of Oracle Applications Schemas ........................................................................2-19
Users, Responsibilities, and Data .........................................................................................2-21
Register Your Oracle User (Schema) ....................................................................................2-22
Add Your Application to a Data Group ..............................................................................2-25
Create a Responsibility ..........................................................................................................2-27
Create an Application User ...................................................................................................2-28
Register Your Tables ..............................................................................................................2-29

3 Overview of the User Interface Standards


Objectives ..........................................................................................................................................3-3
Goals of the User Interface .............................................................................................................3-4
Designing an Applications Interface ............................................................................................3-5
Field-Level Validation Model ........................................................................................................3-6
Elements of the Interface ................................................................................................................3-7
Hybrid Formats ..............................................................................................................................3-10
Window and Block Relationships ...............................................................................................3-12
Master and Detail Block Coordination .......................................................................................3-13
Presentation Models ......................................................................................................................3-15
Dynamic Layouts ...........................................................................................................................3-18
Retrieving Records ........................................................................................................................3-19
Indicating Attributes .....................................................................................................................3-23
Navigation and Function Invocation ..........................................................................................3-24
Exercise ............................................................................................................................................3-26

iv

Extend Oracle Applications: Forms - Table of Contents

4 Overview of Coding Standards


Objectives ..........................................................................................................................................4-3
Benefits of Following Coding Standards .....................................................................................4-4
Goals of the Coding Standards ......................................................................................................4-5
Runtime Environment ....................................................................................................................4-6
Property Classes: Definition ..........................................................................................................4-7
Libraries Provide Useful Routines ................................................................................................4-8
Ensure Your Form Works on the Web .........................................................................................4-9
Build Forms Based on Views .......................................................................................................4-10

5 The Template Form


Objectives ..........................................................................................................................................5-3
Copy TEMPLATE to Start New Forms ........................................................................................5-4
TEMPLATE Inherits Object Groups from APPSTAND .............................................................5-7
Property Classes ..............................................................................................................................5-8
Colors and Visual Attributes .........................................................................................................5-9
Toolbar and Pulldown Menu .......................................................................................................5-10
TEMPLATE Inherits the Calendar ..............................................................................................5-11
Special Triggers in TEMPLATE ...................................................................................................5-13

6 Menus and Function Security


Objectives ..........................................................................................................................................6-3
Understand Function Security: Overview ...................................................................................6-4
Function Security: Definitions .......................................................................................................6-5
Relationship of Function Security to Responsibilities ................................................................6-7
Setting Up Function Security .........................................................................................................6-8
Naming Standards in Function Security ....................................................................................6-11
Building Your Form into Your Application ...............................................................................6-14
Register a Form ..............................................................................................................................6-15
Register Form Functions and Subfunctions ...............................................................................6-16
Create a Menu of Functions .........................................................................................................6-18
Create/Tailor a Responsibility ....................................................................................................6-20
Modify the User Definition ..........................................................................................................6-21

Extend Oracle Applications: Forms - Table of Contents

7 Container Objects
Objectives ..........................................................................................................................................7-3
Modules .............................................................................................................................................7-4
Windows ...........................................................................................................................................7-6
Non-Modal Windows .....................................................................................................................7-8
Modal Windows ...............................................................................................................................7-9
Canvases ..........................................................................................................................................7-10
Blocks ...............................................................................................................................................7-15
Regions ............................................................................................................................................7-22
Navigation ......................................................................................................................................7-27

8 Widgets
Objectives ..........................................................................................................................................8-3
General Properties ...........................................................................................................................8-4
Text Items ..........................................................................................................................................8-5
Display Items ....................................................................................................................................8-7
Check Boxes ......................................................................................................................................8-9
Buttons .............................................................................................................................................8-10
Option Groups ...............................................................................................................................8-13
Poplists ............................................................................................................................................8-15
LOVs ................................................................................................................................................8-17
Descriptive Flexfields ....................................................................................................................8-20
Key Flexfields .................................................................................................................................8-21

9 Layout
Objectives ..........................................................................................................................................9-3
The Layout Process Chronologically ............................................................................................9-4
General Layout Settings ..................................................................................................................9-5
Arranging Items and Translation ..................................................................................................9-6
Cosmetics and Property Classes ....................................................................................................9-8
Accessibility in Oracle Forms Applications .................................................................................9-9
Properties of Block Titles ..............................................................................................................9-14
Regions ............................................................................................................................................9-16
Properties of Region Titles ...........................................................................................................9-19

vi

Extend Oracle Applications: Forms - Table of Contents

Arranging Items .............................................................................................................................9-21


Setting the Prompt Properties of Widget Objects .....................................................................9-23
Single-Record Items ......................................................................................................................9-25
Multi-Row Item Prompts ..............................................................................................................9-27
Check Boxes ....................................................................................................................................9-35
Buttons ............................................................................................................................................9-37
Option Groups ...............................................................................................................................9-38
Descriptive Flexfields ....................................................................................................................9-39
Properties of Dynamic Prompts and Titles ................................................................................9-40
Conventions ....................................................................................................................................9-41

10 Coding with PL/SQL


Objectives ........................................................................................................................................10-3
Overview of Coding with PL/SQL .............................................................................................10-4
Use Handlers to Organize Code ..................................................................................................10-5
Item Handlers Validate Items ......................................................................................................10-6
Event Handlers Control Events ...................................................................................................10-8
Table Handlers Manipulate Tables .............................................................................................10-9
Database Tier or Application Tier? ...........................................................................................10-10
Follow Coding Standards ...........................................................................................................10-11
Replacements for Oracle Forms Built-Ins ................................................................................10-13
Coding Triggers ...........................................................................................................................10-14
Review: Triggers in TEMPLATE ...............................................................................................10-16
Record history (WHO): Track Data Changes ..........................................................................10-18
Debugging Your Forms ..............................................................................................................10-20
Using Examine to Debug Your Forms ......................................................................................10-21

11 Coding Window and Region Behavior


Objectives ........................................................................................................................................11-3
Master and Detail Windows ........................................................................................................11-4
Controlling Your Windows ..........................................................................................................11-6
Tabbed Regions: Three Degrees of Coding Difficulty .............................................................11-9
Many Types of Tabbed Regions ................................................................................................11-10
Characteristics of Tabbed Regions ............................................................................................11-15
Creating Tab Canvases ...............................................................................................................11-17

Extend Oracle Applications: Forms - Table of Contents

vii

Tab Related Code .........................................................................................................................11-18


Example of Building a Tabbed Region (Fixed Field Case) ....................................................11-20

12 Coding Item Behavior


Objectives ........................................................................................................................................12-3
Formatting Currency Fields .........................................................................................................12-4
Calendar - Lets Make a Date .......................................................................................................12-5
Flexible Dates .................................................................................................................................12-7
Overview of Numbers .................................................................................................................12-11
Coding Dependencies Between Items ......................................................................................12-14
Dynamic Item Properties ............................................................................................................12-24
Item-level and Item-instance-level Properties .........................................................................12-26
Getting Item Properties ...............................................................................................................12-27
Using User Profiles in Your Form .............................................................................................12-28
FND: Override Directory Profile Option for Developers ..................................................12-31

13 Message Dictionary
Objectives ........................................................................................................................................13-3
Message Dictionary Overview .....................................................................................................13-4
Define Messages for Your Application .......................................................................................13-5
Message Content Standards .........................................................................................................13-7
Generate Message Files .................................................................................................................13-9
Displaying Messages Is a Two-Phase Process .........................................................................13-10
Set Up Messages in the Form .....................................................................................................13-11
Display Your Message in the Form ...........................................................................................13-15
Call Messages from the Server ...................................................................................................13-21
Other Useful Message Routines ................................................................................................13-23

14 Flexfields
Objectives ........................................................................................................................................14-3
Benefits of Flexfields ......................................................................................................................14-4
Look at a Flexfield ..........................................................................................................................14-5
When to Use A Flexfield ...............................................................................................................14-9
Your End Users Perspective ......................................................................................................14-10

viii

Extend Oracle Applications: Forms - Table of Contents

Intelligent Keys ............................................................................................................................14-11


Key Flexfields in Oracle Applications ......................................................................................14-13
Create Key flexfield Combinations ...........................................................................................14-14
Key Flexfield Combinations Table ............................................................................................14-15
Use Three Types of Key Flexfield Forms .................................................................................14-17
Use Qualifiers to Identify Key Segments .................................................................................14-21
Use Segment Qualifiers to Identify Values ..............................................................................14-25
Create New Combinations Dynamically .................................................................................14-27
Descriptive Flexfields Table Structure ......................................................................................14-29
Overview of Developing a Flexfield .........................................................................................14-30
Stage 1: Designing the Table Structure ..............................................................................14-31
Stage 2: Creating the Fields .................................................................................................14-35
Stage 3: Calling Flexfield Routines ....................................................................................14-37
Stage 4: Registration .............................................................................................................14-44
Stage 5: Definition ................................................................................................................14-51
Flexfield View Generation ..........................................................................................................14-60

15 Query Find
Objectives ........................................................................................................................................15-3
Overview of Query Find ...............................................................................................................15-4
Create a Row-LOV .........................................................................................................................15-7
Create a Find Window ..................................................................................................................15-8

16 Menus and Advanced Function Security


Objectives ........................................................................................................................................16-3
Understand Function Security: Review .....................................................................................16-4
Review: Subfunction Naming Standards ...................................................................................16-5
Register Form Functions and Subfunctions ...............................................................................16-6
Create a Menu of Functions .........................................................................................................16-7
Advanced Function Security ........................................................................................................16-8
Code the Form to Test a Subfunction .........................................................................................16-9
Open Forms from Form Logic ...................................................................................................16-10
Add Choices to the Special Menus ...........................................................................................16-12
Example: Using the Special Menu with FND_FUNCTION.TEST ........................................16-16
Right Mouse Button Menus (Popup Menus) ...........................................................................16-17

Extend Oracle Applications: Forms - Table of Contents

ix

Coding Custom Right Mouse Button Menu Entries ...............................................................16-18

17 Attachments
Objectives ........................................................................................................................................17-3
Overview of the Attachments Feature ........................................................................................17-4
Definitions .......................................................................................................................................17-5
Plan the Attachments Feature for Your Application ................................................................17-7
Define the Attachments Feature ...................................................................................................17-9
Set Up Entities ..............................................................................................................................17-10
Set Up Document Categories .....................................................................................................17-11
Set Up Attachment Functions ....................................................................................................17-12
Add and View Attachments from Your Form .........................................................................17-16

A - Order Entry Workshop


Your Order Entry Workshop Project ...........................................................................................A-3
Order Form Specifications .............................................................................................................A-4
Order Form Inquiry Features ........................................................................................................A-8
Tables and Predefined Data: Salespeople .................................................................................A-10
Tables and Predefined Data: Customers ...................................................................................A-14
Tables and Predefined Data: Products ......................................................................................A-17
Tables and Predefined Data: Orders ..........................................................................................A-21
Tables and Predefined Data: Order Lines .................................................................................A-29
Register Flexfield Tables ..............................................................................................................A-34

B - Practices
Login Information B-3
Lab 1: Architecture .................................................................................................................. B-4
Lab 2: Menus and Function Security .................................................................................... B-5
Lab 3: Container Objects ......................................................................................................... B-7
Lab 4: Widgets ........................................................................................................................ B-12
Lab 5: Layout .......................................................................................................................... B-18
Lab 6: Enhance Items: Create LOVs .................................................................................... B-20
Lab 7: Coding with PL/SQL ................................................................................................ B-22
Lab 8: Controlling Windows ................................................................................................ B-26

Extend Oracle Applications: Forms - Table of Contents

Lab 9: Tabbed Regions .......................................................................................................... B-28


Lab 10: Currency Fields ........................................................................................................ B-31
Lab 11: Runtime Behavior .................................................................................................... B-32
Lab 12: Conditionally Dependent Items ............................................................................ B-33
Lab 13: Message Dictionary ................................................................................................. B-34
Lab 14: Flexfields ................................................................................................................... B-35
Lab 15: Query Find ................................................................................................................ B-36
Lab 16: Advanced Function Security .................................................................................. B-37
Lab 17: Setting Up Attachments .......................................................................................... B-39
Lab 18: Testing and Reviewing Your Form ....................................................................... B-41

C - Practices and Solutions


Login Information .......................................................................................................................... C-3
Lab 1: Architecture .................................................................................................................. C-4
Lab 2: Menus and Function Security .................................................................................... C-5
Lab 3: Container Objects ......................................................................................................... C-8
Lab 4: Widgets ....................................................................................................................... C-15
Lab 5: Layout .......................................................................................................................... C-21
Lab 6: Enhance Items: Create LOVs .................................................................................... C-24
Lab 7: Coding with PL/SQL ................................................................................................ C-28
Lab 8: Controlling Windows ................................................................................................ C-35
Lab 9: Tabbed Regions .......................................................................................................... C-40
Lab 10: Currency Fields ........................................................................................................ C-48
Lab 11: Runtime Behavior .................................................................................................... C-51
Lab 12: Conditionally Dependent Items ............................................................................ C-53
Lab 13: Message Dictionary ................................................................................................. C-57
Lab 14: Flexfields ................................................................................................................... C-59
Lab 15: Query Find ................................................................................................................ C-63
Lab 16: Advanced Function Security .................................................................................. C-65
Lab 17: Setting Up Attachments .......................................................................................... C-68
Lab 18: Testing and Reviewing Your Form ....................................................................... C-70

Extend Oracle Applications: Forms - Table of Contents

xi

xii

Extend Oracle Applications: Forms - Table of Contents

You might also like