In this post I will attempt to explain how to dynamically assign a prompt table depending on a drop down value (see image below)

The table behind the grid is PORTAL_SECDYVW and as you can see from the image below, the PORTAL_AUTHNAME field has %EDITTABLE defined as a prompt table. The PORTAL_AUTHNAME is the "Name" column you see on the grid.

A very simple yet very useful code to give users the option to delete all grid rows on a page at once. I've implemented such a requirement by placing a "Delete all" button above a grid to give PeopleSoft users the option to delete all rows at once instead of clicking the "-" grid button. If the gird has, lets say, 20 rows, then a user will have to click the "-" delete grid button 20 times to delete all rows, compared to one click on the "Delete all" button.
Place the code below behind a field change event.
If you use APP ENGINE to report the data from the temp table /staging table on to CSV file using excel format, there is a known issue with fields that have leading zeros. For ex:You have a field of length 6 characters. If the field value is 002123, the excel file removes the leading zeros. But if the requirement is to preserve those leading zeros, we can do something like this.
Update the temp table right before you write out into a file.
The function increments a date field using the AddToDate function and sets a weekday field to the corresponding weekday. You can increment date value by year, month or day.
A function to facilitate the addition of a leading character to a field value. The function takes three parameters:
- &LEADCHAR: The character you want to append to your value.
- &FIELDZISE: The over all size of your value after appending your desired character.
- &FIELDVALUE: The value you want to append the character to.
Syntax
str: value to be passed to the function.
Example:
The example sets &VAL1 to 5.25 and &VAL2 to 500:
&VAL1 = Value("5.25");
&VAL2 = Value("500");
Check out the following post to convert a number variable type to a string type.
Syntax
Check out the following post to convert a string variable type to a number type.
I have code to auto-increment an alphanumeric field, using SQL calls. It is specific to a 4-character field, but can easily be adapted to different length fields.
Peoplesoft provides a function called as "DateTimeToLocalizedString" to change date from one format into another.
Following is syntax used to achiev this.
DateTimeToLocalizedString({datetime | date}, [Pattern])
Param1 : Variable of Date Datatype
Param2 : Date format which you want for example "dd/MM/yyyy".
If you have Param1 of type string then use function "DateValue" to convert that string to Date.
This code i have got Ittool box.com.
It is very useful. we usually have requirement when we want to hide some translate values from translate field on page for some business reason.
In this case we can use AddDropDownItem(),ClearDropDownItem().
The fact is that we need to use ClearDropDownItem() function first. so whatever values it had will be cleared out and then we will have to manually add values using AddDropDownItem().
Here is an example on the page activate PeopleCode.
| Title | Under | Posted on |
|---|---|---|
| Abs Mgmt: How can Abs rule pro-rate contractor's last month's entitlement (need help urgently) | PeopleSoft Functional | 03/10/2010 - 9:21pm |
| Can we user LONG datatype as a search option in PeopleSoft | PeopleSoft Technical | 03/10/2010 - 11:22am |
| special caracters are not translated correctly when ftp from windows to unix | Programming | 03/09/2010 - 3:23pm |
| How to view the employees from particular country in peoplesoft? | PeopleSoft Technical | 03/03/2010 - 1:56am |
Recent comments
3 hours 51 min ago
1 day 20 hours ago
6 days 7 hours ago
1 week 10 hours ago
1 week 10 hours ago
1 week 12 hours ago
1 week 1 day ago
1 week 1 day ago
1 week 1 day ago
1 week 1 day ago