34
Eyad Alshareef 1 Introduction To Introduction To Form Builder Form Builder Part B Part B

Eyad Alshareef 1 Introduction To Form Builder Part B

Embed Size (px)

Citation preview

Page 1: Eyad Alshareef 1 Introduction To Form Builder Part B

Eyad Alshareef 1

Introduction To Introduction To Form Builder Form Builder

Part BPart B

Page 2: Eyad Alshareef 1 Introduction To Form Builder Part B

2Eyad Alshareef

ObjectivesObjectives

Create data block from viewCreate data block from view Modify properties using Property Modify properties using Property

PalettePalette Text item propertiesText item properties

Master-detail relationshipMaster-detail relationship Create master block firstCreate master block first Specify relationship automatically or Specify relationship automatically or

manuallymanually

Page 3: Eyad Alshareef 1 Introduction To Form Builder Part B

3Eyad Alshareef

Creating a Form Based Creating a Form Based on a Database Viewon a Database View

View can be derived from one or View can be derived from one or more database tablesmore database tables

Form based on a view allows you to Form based on a view allows you to display data from table(s)display data from table(s)

Form could be used to insert, Form could be used to insert, update, or delete data if the view is a update, or delete data if the view is a simple view only. simple view only.

Page 4: Eyad Alshareef 1 Introduction To Form Builder Part B

4Eyad Alshareef

Creating a Form Based Creating a Form Based on on

a Database Viewa Database View Similar to form based on table but read-onlySimilar to form based on table but read-only

Page 5: Eyad Alshareef 1 Introduction To Form Builder Part B

Eyad Alshareef 5

Modifying Modifying PropertiesProperties

Page 6: Eyad Alshareef 1 Introduction To Form Builder Part B

6Eyad Alshareef

Modifying Form Modifying Form PropertiesProperties

Page 7: Eyad Alshareef 1 Introduction To Form Builder Part B

7Eyad Alshareef

Guidelines For Guidelines For Configuring Form Configuring Form

WindowsWindows1.1. Change the window titleChange the window title2.2. Allow user to minimize the windowAllow user to minimize the window3.3. Do not allow the user to maximize the Do not allow the user to maximize the

windowwindow4.4. Do not allow the user to resize the windowDo not allow the user to resize the window5.5. Include horizontal and vertical scrollbars if Include horizontal and vertical scrollbars if

items appear beyond window boundariesitems appear beyond window boundaries6.6. Make the form window fill the Forms Make the form window fill the Forms

Runtime windowRuntime window

Page 8: Eyad Alshareef 1 Introduction To Form Builder Part B

8Eyad Alshareef

Configuring Form Configuring Form WindowsWindows

Window Title

Minimize/Maximize buttons

Windowsize

Page 9: Eyad Alshareef 1 Introduction To Form Builder Part B

9Eyad Alshareef

Property PaletteProperty Palette

CE
Slide title is figure caption, not heading - okay?Also, this figure may be a little hard to read since it was scaled down so much.
Page 10: Eyad Alshareef 1 Introduction To Form Builder Part B

10Eyad Alshareef

Modifying Form Modifying Form PropertiesProperties

Every form object has a Every form object has a Property Property PalettePalette that allows you to configure that allows you to configure form propertiesform properties

PropertyNodes Property List

Page 11: Eyad Alshareef 1 Introduction To Form Builder Part B

11Eyad Alshareef

Modifying Form Modifying Form PropertiesProperties

Use Property Palette of form object to modify Use Property Palette of form object to modify desired propertiesdesired properties To access: right click object, select Property Palette To access: right click object, select Property Palette

from menufrom menu Intersection mode modifies properties for multiple Intersection mode modifies properties for multiple

objects at the same timeobjects at the same time To open in intersection mode, select multiple objects To open in intersection mode, select multiple objects

before opening Property Palettebefore opening Property Palette

Page 12: Eyad Alshareef 1 Introduction To Form Builder Part B

12Eyad Alshareef

Property PaletteProperty Palette

Page 13: Eyad Alshareef 1 Introduction To Form Builder Part B

13Eyad Alshareef

Intersection Property Intersection Property PalettePalette

Used to change property of several Used to change property of several items to the same valueitems to the same value Intersection/Union button appears as Intersection/Union button appears as Name appears as Name appears as **********

Page 14: Eyad Alshareef 1 Introduction To Form Builder Part B

14Eyad Alshareef

Frame PropertiesFrame Properties Update LayoutUpdate Layout

AutomaticallyAutomatically Frame items are automatically repositioned based on Frame items are automatically repositioned based on

their order in the Data Blocks list when you move or their order in the Data Blocks list when you move or resize a frame, or modify the form layout using the resize a frame, or modify the form layout using the Layout Wizard in reentrant modeLayout Wizard in reentrant mode

ManuallyManually Items are automatically when layout is modified in Items are automatically when layout is modified in

Layout Wizard in reentrant modeLayout Wizard in reentrant mode Items are not repositioned if you move or resize the Items are not repositioned if you move or resize the

frameframe LockedLocked

Items are never automatically repositionedItems are never automatically repositioned

Page 15: Eyad Alshareef 1 Introduction To Form Builder Part B

15Eyad Alshareef

Modifying Text Item Modifying Text Item Properties Using the Properties Using the

Property PaletteProperty Palette Intersection modeIntersection mode

Values appears as **** when objects Values appears as **** when objects have different valueshave different values

Text item properties Text item properties Control how users enter data values Control how users enter data values How form displays data valuesHow form displays data values

HintHint ToolTipToolTip

CE
There is no slide for "Modifying Form Promts and Prompt Properties Using the Layout Editor" (pg 327) - okay?
Page 16: Eyad Alshareef 1 Introduction To Form Builder Part B

16Eyad Alshareef

Text item Appearance Text item Appearance PropertiesProperties

CE
Slide title is figure caption, not heading - okay?
Page 17: Eyad Alshareef 1 Introduction To Form Builder Part B

17Eyad Alshareef

Text Item Data Value Text Item Data Value PropertiesProperties

CE
Slide title is figure caption, not heading - okay?
Page 18: Eyad Alshareef 1 Introduction To Form Builder Part B

18Eyad Alshareef

Text Item Database Text Item Database PropertiesProperties

CE
Slide title is figure caption, not heading - okay?
Page 19: Eyad Alshareef 1 Introduction To Form Builder Part B

Eyad Alshareef 19

Master-detail Master-detail relationshiprelationship

Page 20: Eyad Alshareef 1 Introduction To Form Builder Part B

20Eyad Alshareef

Data block forms can display data Data block forms can display data from multiple tables that have a from multiple tables that have a master-detail master-detail relationshiprelationship Master record has multiple related Master record has multiple related

detail recordsdetail records Examples:Examples:

One ITEM record has multiple related One ITEM record has multiple related INVENTORY recordsINVENTORY records

One CUSTOMER might have multiple One CUSTOMER might have multiple CUST_ORDER recordsCUST_ORDER records

Multiple-Table FormsMultiple-Table Forms

Page 21: Eyad Alshareef 1 Introduction To Form Builder Part B

21Eyad Alshareef

Creating the Detail Data Creating the Detail Data BlockBlock

Master-Detail pageMaster-Detail page Auto-join feature of Data Block Auto-join feature of Data Block

WizardWizard Create link manuallyCreate link manually

Click Create RelationshipClick Create Relationship Explicitly select related itemsExplicitly select related items

Join Condition field syntax:Join Condition field syntax: detail_blockdetail_block..join_itemjoin_item = = master_blockmaster_block..join_itemjoin_item

Page 22: Eyad Alshareef 1 Introduction To Form Builder Part B

22Eyad Alshareef

Master block

Detail block

Master-Detail FormsMaster-Detail Forms

Page 23: Eyad Alshareef 1 Introduction To Form Builder Part B

23Eyad Alshareef

Multiple Master-Detail Multiple Master-Detail BlocksBlocks

Page 24: Eyad Alshareef 1 Introduction To Form Builder Part B

24Eyad Alshareef

Creating a Master-Detail Creating a Master-Detail FormForm

Create the Create the master block master block firstfirst

Specify the Specify the relationship relationship on the Data on the Data Block Wizard Block Wizard Master-Master-Detail page Detail page of the detail of the detail blockblock

Page 25: Eyad Alshareef 1 Introduction To Form Builder Part B

25Eyad Alshareef

A master block can have multiple detail A master block can have multiple detail blocksblocks An item can be in multiple customer orders, An item can be in multiple customer orders,

and have multiple shipment recordsand have multiple shipment records A detail block can be a master block in a A detail block can be a master block in a

second master-detail relationshipsecond master-detail relationship A customer can have multiple CUST_ORDER A customer can have multiple CUST_ORDER

recordsrecords One CUST_ORDER record can have multiple One CUST_ORDER record can have multiple

ORDER_LINE recordsORDER_LINE records

Complex Master-Detail Complex Master-Detail RelationshipsRelationships

Page 26: Eyad Alshareef 1 Introduction To Form Builder Part B

26Eyad Alshareef

Master

Detail MasterDetail

Complex Master-DetailComplex Master-DetailRelationship ExampleRelationship Example

Page 27: Eyad Alshareef 1 Introduction To Form Builder Part B

27Eyad Alshareef

Creating a form based on two Creating a form based on two linked tableslinked tables In order to create a form based on 2 In order to create a form based on 2

tables:tables: Create a form similar to the STUDENT form Create a form similar to the STUDENT form

we created (name it REGISTRATION)we created (name it REGISTRATION) Create an additional data block using a wizardCreate an additional data block using a wizard Establish master-detail relationshipEstablish master-detail relationship

Page 28: Eyad Alshareef 1 Introduction To Form Builder Part B

28Eyad Alshareef

Creating a form based on Creating a form based on two linked tablestwo linked tables

Follow the steps suggested by the Follow the steps suggested by the wizardwizard

Page 29: Eyad Alshareef 1 Introduction To Form Builder Part B

29Eyad Alshareef

For the STUD_COURSE frame, select tabular For the STUD_COURSE frame, select tabular layout, 4 records per page and a scrollbar.layout, 4 records per page and a scrollbar.

Creating a form based on Creating a form based on two linked tablestwo linked tables

Page 30: Eyad Alshareef 1 Introduction To Form Builder Part B

30Eyad Alshareef

Compile and run your Compile and run your formform

Page 31: Eyad Alshareef 1 Introduction To Form Builder Part B

Eyad Alshareef 31

Formatting Mask Formatting Mask

Page 32: Eyad Alshareef 1 Introduction To Form Builder Part B

32Eyad Alshareef

Formatting Text ItemsFormatting Text Items

Specify desired format mask in text Specify desired format mask in text item Format Mask propertyitem Format Mask property If format mask makes value wider than If format mask makes value wider than

text item Data Width property, data text item Data Width property, data appears as appears as ########## E.g: make the format mask for the empno E.g: make the format mask for the empno

field in the form builder: 99”- - “ 99 and field in the form builder: 99”- - “ 99 and make the data length for the field 4.make the data length for the field 4.

Page 33: Eyad Alshareef 1 Introduction To Form Builder Part B

33Eyad Alshareef

Formatting Character Formatting Character Text ItemsText Items

Place embedded characters in Place embedded characters in double quotesdouble quotes

Page 34: Eyad Alshareef 1 Introduction To Form Builder Part B

34Eyad Alshareef

Format Mask ExamplesFormat Mask Examples

Value Format Mask ResultValue Format Mask Result

7945 999 ###7945 999 ###

7945 9999$ 7945$7945 9999$ 7945$

7945 99”-”99 79-457945 99”-”99 79-45

34.28 99.9 34.334.28 99.9 34.3

34.28 99.999 34.28034.28 99.999 34.280

SYSDATE Day-MON-YY Friday-NOV-06SYSDATE Day-MON-YY Friday-NOV-06