Showing posts with label Forms Personalization.. Show all posts
Showing posts with label Forms Personalization.. Show all posts

Friday, November 28, 2014

Display Message from FND_MESSAGES using Forms Personalization.

Responsibility: Application Developer
Navigation: Application > Messages



Create new message
Name: XX_TEST
Current Text Message: This is a test message for &USER_NAME



Save and close form.
Generate the message
Responsibility: Application Developer
Click on View > Requests in the menu to execute a concurrent program. Select Generate Messages program.





Click on Help > Diagnostics > Custom Code > Personalize
Create a new Personalization





Click on Actions

Sequence 10
Type: Builtin
Description: Retrieve the msg
Builtin Type: Execute a procedure
Argument: FND_MESSAGE.SET_NAME(‘XXCUST’, ‘XX_TEST’)




Sequence 11

Type: Builtin
Description: Set the USER token
Builtin Type: Execute a Procedure
Argument: fnd_message.set_token (‘USERNAME’, fnd_profile.value(‘USERNAME’))



Sequence 12

Type: Builtin
Description: Set the ORG token
Builtin Type: Execute a Procedure
Argument: fnd_message.set_token (‘ORG_ID’, fnd_profile.value(‘ORG_ID’))



Sequence 13
Type: Message
Description: Display the msg
Message Type: Show
Message Text: =FND_MESSAGE.GET





Challa.

Monday, July 7, 2014

Calling Stored procedure through Forms Personalization

Steps:

1. Personalize the form
2. Create an action of type “BuiltIn”
3. BuiltIn Type for Action should be “Execute a Procedure”
4. Argument should be as below
=’declare
v_field_value VARCHAR2(200) ;
begin
plsql_package.procedurenameHere ;
end’

or alternately

=’declare
v_field_value VARCHAR2(200) ;
begin
XX_PRC(”’||${item.PO_CONTROL_RULES.OBJECT_CODE_DISPLAYED_VALUE.value}||”’);
end’

Note the syntax, after =, entire declare begin end is within single quote.

Also, there is no semi colon after “end”
You can pass field values as
”’||${item.BLOCKNAME.FIELDNAME.value}||”’

Example:
 
A simple way to understand is the begin end block should be enclosed in single quotes and the fields should be enclosed in double quotes.

=‘begin
test_procedure( “’||:GLOBAL.field||’”,”‘||${item.block.field.value}||’”);
end’

Challa.

Tables for Forms Personalization

Below is the list of tables that are populated when any Forms Personalization is done

FND_FORM_CUSTOM_RULES
FND_FORM_CUSTOM_SCOPES
FND_FORM_CUSTOM_ACTIONS
FND_FORM_CUSTOM_PARAMS
FND_FORM_CUSTOM_PROP_VALUES
FND_FORM_CUSTOM_PROP_LIST

You can use the FNDLOAD utility to move the peronalizations from one instance to another.

Example Synatx shown below to download or upload Form Personalizations.

Download Personalizations

1) FNDLOAD apps/appspwd 0 Y DOWNLOAD $FND_TOP/patch/115/import/affrmcus.lct XX_OEXOEORD.ldt FND_FORM_CUSTOM_RULES form_name=”OEXOEORD”

2) FNDLOAD apps/appspwd 0 Y DOWNLOAD $FND_TOP/patch/115/import/affrmcus.lct XX_OEXOETEL.ldt FND_FORM_CUSTOM_RULES form_name=”OEXOETEL”

Upload Personalizations

1) FNDLOAD apps/appspwd 0 Y UPLOAD $FND_TOP/patch/115/import/affrmcus.lct XX_OEXOEORD.ldt

2) FNDLOAD apps/appspwd 0 Y UPLOAD $FND_TOP/patch/115/import/affrmcus.lct XX_OEXOETEL.ldt

The below script list all the forms in Oracle Applications that have been customized using Forms Personlization:

/* Formatted on 2014/07/17 19:02 (Formatter Plus v4.8.8) */
SELECT   ffv.form_id, ffv.form_name, fat.application_name, ffv.user_form_name,
                 ffv.description "Form Description", ffcr.SEQUENCE,
                 ffcr.description "Personalization Rule Name"
    FROM fnd_form_vl ffv, fnd_form_custom_rules ffcr, fnd_application_tl fat
   WHERE ffv.form_name = ffcr.form_name
     AND    fat.application_id = ffv.application_id
ORDER BY  ffv.form_name, ffcr.SEQUENCE;
Challa.

Forms Personalization.

With the Oracle E-Business Suite release 11.5.10, the Oracle has introduced a mechanism which revolutionizes the way the forms can be customized to fulfill the customer needs. For many years, Oracle Applications has provided a custom library using which the look and behavior of the standard forms can be altered, but the custom library modifications require extensive work on SQL and PL/SQL. In the release 11.5.10, Oracle has provided a simple and easy feature to implement the customer specific requirements without modifying the underlying forms code or CUSTOM library. Although CUSTOM library still can be used for forms customization to implement the complex business logic, the personalization feature provided in the latest release is easy, faster and requires minimum development effort.

Why Forms Personalization?
  • Oracle Supports personalization unlike customization.
  • Personalizations are stored in tables rather than files.
  • Will not have a bigger impact when you upgrade or apply patches to the environment.
  • Can be moved easily through FNDLOAD from one instance to other.
  • Can be restricted at site/responsibility/user level.
  • Easy to disable/enable with click of a button.
  • Personalization stores who columns with which we have the ability to track who created/modified it where as in CUSTOM.PLL we don’t have that ability.
  • Can be applied to new responsibilities/users easily.
  • Can be restricted to a function or form.
What can be implemented through Forms Personalization?

The below can be done using Personalization:
  • Zoom from one form to another.
  • Pass data from one form to another through global variables.
  • Change LOV values dynamically.
  • Enable/Disable/Hide fields dynamically
  • Display user friendly messages when required
  • Launch URL directly from oracle form
  • Execute PL/SQL programs through FORM_DDL package
  • Call custom libraries dynamically
Personalization Tables:
  • FND_FORM_CUSTOM_RULES
  • FND_FORM_CUSTOM_ACTIONS
  • FND_FORM_CUSTOM_SCOPES
  • FND_FORM_CUSTOM_PARAMS
  • FND_FORM_CUSTOM_PROP_LIST
  • FND_FORM_CUSTOM_PROP_VALUES
Invoking the Personalization screen:

The personalization form should be used to implement the custom rules on a specific form. The specific form refers to the desired form on which you want to apply the custom business logic or modify the form behavior.

The personalization form is invoked by…

Menu Navigation: Help > Diagnostics > Custom Code > Personalize

Disable the personalization feature:

It is possible that a change you make completely breaks a form, to the point that it will not even run! Here’s how to recover:
  • On the pulldown menu, choose Help > Diagnostics > Custom Code > Off
  • This will disable all callouts to Forms Personalization
  • Run the form of interest
  • It should run now, because your changes were skipped
  • Invoke the Personalization screen and correct the problem
  • On the pulldown menu, choose Help > Diagnostics > Custom Code > Normal to re-enable processing of Personalizations
Limitations:

Although it is faster than a speeding bullet, it is not able to leap over tall buildings:
  • You can only change what Forms allows at runtime:
  1. Cannot create new items
  2. Cannot move items between canvases
  3. Cannot display an item which is not on a canvas
  4. Cannot set certain properties
  5. Cannot change frames, graphics, boilerplate
  • You can only respond to certain Trigger Events:
  1. WHEN-NEW-FORM-INSTANCE, WHEN-NEW-BLOCK-INSTANCE, WHEN-NEW-RECORD-INSTANCE, WHEN-NEW-ITEM-INSTANCE
  2. WHEN-VALIDATE-RECORD (not in all forms)
  3. Product-specific events
  • May interfere with, or be overridden by, base product code
  • Expected user is an Admin/Developer
  1. Knowledge of Oracle Developer is extremely desirable
  2. Knowledge of PL/SQL, Coding Standards and/or APIs required in some cases
  • Normal rules for customizations apply
  1. Extensive testing in a Test environment is required!
Relationship with CUSTOM library:
  • CUSTOM is a stub library Oracle ships that receives Trigger Events. Customers are free to add any code they like to it.
  • CUSTOM and Form Personalizations drive off the same Trigger Events.
  • Form Personalizations are processed first, then the event is sent to CUSTOM
  • CUSTOM can do more because it has complete access to all PL/SQL and SQL.
  • But for most changes, Form Personalizations is adequate and is significantly simpler. 

Challa.