APEX ADVANCED TUTORIALS

  • View
    114

  • Download
    5

Embed Size (px)

DESCRIPTION

APEX ADVANCED TUTORIALS

Text of APEX ADVANCED TUTORIALS

Introduction to Oracle APEX IIVersion 3.2 Workbook

Introduction to Oracle APEX II Workbook - Version 3.2

Table of Contents1. Installation! ................................................................................................................................................................4 1.1. Download & Unzip Class Files!.................................................................................................................4 1.2. Login to Your Workspace!...........................................................................................................................4 1.3. Import the Starter Application!..................................................................................................................4 JavaScript & Ajax!....................................................................................................................................................6 2.1. onload Events: Display an Alert!...............................................................................................................6 2.2. onblur Events: Change Case to Upper!....................................................................................................7 2.3. onblur Events: Change Background Color!.............................................................................................8 2.4. onkeypress Events: Character Counter & Hide/Show !.......................................................................10 2.5. Modify conrmDelete Parameters!.........................................................................................................13 2.6. Item Validations!........................................................................................................................................14 2.7. Hide & Show Regions! ...............................................................................................................................16 Ajax! ...........................................................................................................................................................................18 3.1. Create an AutoAssign Function!..............................................................................................................18 3.2. Automatically Set Status to Closed!.........................................................................................................21 Security!....................................................................................................................................................................23 4.1. Session Timeout!.........................................................................................................................................23 4.2. Encrypted Session State!............................................................................................................................26 4.3. Save Session State Before Branching! .......................................................................................................28 4.4. Autocomplete!.............................................................................................................................................29 4.5. Monitoring APEX Logs!............................................................................................................................31 Performance Tuning !.............................................................................................................................................32 5.1. Debug Mode! ...............................................................................................................................................32 5.2. Timings! ........................................................................................................................................................35 5.3. Page & Region Caching!............................................................................................................................36 Developer Tools!.....................................................................................................................................................37 6.1. Page Locks!..................................................................................................................................................37 6.2. Page Groups! ...............................................................................................................................................41 6.3. Build Options!.............................................................................................................................................44 User Interface!.........................................................................................................................................................46 7.1. Import the Theme Starter Application!...................................................................................................46 7.2. Create a New Theme!.................................................................................................................................47 7.3. Set Up a Custom Directory on the HTTP Server!..................................................................................49 7.4. Create a Page Template!............................................................................................................................50 7.5. Create Region Templates!..........................................................................................................................56 7.6. Create List Templates! ................................................................................................................................58 7.7. Create Regions!...........................................................................................................................................59

2.

3.

4.

5.

6.

7.

Copyright 2009-2010 Sumneva

Page 2

Introduction to Oracle APEX II Workbook - Version 3.2

ConventionsThe following typeset conventions are used throughout this document: Plain Text Plain text is nothing more than standard, narrative text. No special actions are required. Fixed Width! Fixed width is used to denote input required from the user. When something is in the fixed width font, that text should be entered into the corresponding eld or region. Bold Bold is used to indicate that you should perform an action, such as clicking a link or pressing a button, which corresponds to the value of the Bold text. Bold Underline Bold Underline is used to refer to a label or section of a page. Bold Underline labels will typically denote where an action should occur, not the action itself.

Comments & QuestionsAny comments or questions on this material should be directed to: Sumneva info@sumneva.com (703) 879-4615

Copyright InformationThis document is Copyright 2009-2010, by Sumneva. None of it in part or in whole may be reproduced without prior written consent from Sumneva.

Copyright 2009-2010 Sumneva

Page 3

Introduction to Oracle APEX II Workbook - Version 3.2

1.

INSTALLATION

1.1. Download & Unzip Class FilesTo make things easier, most code snippets can simply be copied & pasted from a set of text les. Before we begin, youll need to download and expand the ZIP le that contains these les. In some cases, the les may already be on your workstation. 1) Open a new browser window. 2) Navigate to the following URL to download the class les: http://sumneva.com/c/sumneva/training/intro2.zip 3) Unzip the contents to your desktop or anywhere on your hard drive that is easily accessible.

1.2. Login to Your WorkspaceAll of the work that you will do will occur in your workspace. Each workspace is mapped to its own schema, and each student has their own workspace, so nothing you can do can impact anyone else in the class. 1) Navigate to the URL provided by the instructor. 2) Using the credentials either found in your workbook or provided by your instructor, log in to your workspace.

1.3. Import the Starter ApplicationIf you did not just take Introduction to Oracle APEX I, then you will need to complete this step. 1) Click on the Application Builder tab. 2) Click Import. 3) Click Browse and locate and select the le 1.3_apex.sql, which can be found where you extracted the class les in Section 1.1. 4) Click Next. 5) Click Next again. 6) Select your Parsing Schema, set the Build Status to Run and Build Application, set Install As Application to Auto Assign New Application ID and click Install.

Copyright 2009-2010 Sumneva

Page 4

Introduction to Oracle APEX II Workbook - Version 3.2

7) Make sure that Install Supporting Objects is set to Yes and click Next. 8) Click Install. At this point, you should see the following screen:

If there is any warning or error message present, please notify your instructor. Your application should have four users: Username Scott Shannon Isabella Owen Password sumneva sumneva sumneva sumneva Privilege Administrator Edit Edit View

Administrators will be able to do everything in the system, including managing users and access control lists. Edit users will be able to change any data, but will not be able to manage users and access control lists. All view users will be able to do is view transactional data. 9) Run your application and sign on as Scott. Take some time to become familiar with the application, if you have not done so already.

Copyright 2009-2010 Sumneva

Page 5

Introduction to Oracle APEX II Workbook - Version 3.2

2.

JAVASC R I P T

&

A JAX

2.1. onload Events: Display an AlertWhen a page loads in APEX or any other HTML-based technology, we can trap th