Do not use Error or
Warning statements in RowInit PeopleCode: these cause a runtime error.
RowInit PeopleCode is
often paired with FieldChange PeopleCode. In these RowInit/FieldChange pairs,
the RowInit PeopleCode checks values in the component and initializes the state
or value of page controls accordingly. FieldChange PeopleCode then rechecks the
values in the component during page execution and resets the state or value of
page controls.
RowInit PeopleCode
can be associated with record fields and component records.
More general
initialization of the component should be done in PostBuild PeopleCode, not
RowInit.
PeopleCode for
processing specific to the insertion of new rows. Do not put PeopleCode in
RowInsert that already exists in RowInit, because a RowInit event always
initiates after the RowInsert event, which will cause your code to be run
twice.
Do not use a warning
or error in RowInsert.
You can prevent a
user from inserting rows into a scroll area by selecting the No Row Insert
check box in the scroll bar’s page field properties, as shown in the following
illustration. However, you cannot prevent row insertion conditionally.
RowInsert does not
trigger PeopleCode on derived/work fields.
The RowSelect event
is initiated at the beginning of the component build process in any of the
update action modes (Update, Update/Display All, Correction). RowSelect
PeopleCode is used to filter out rows of data as they are being read into the
component buffer. This event also occurs after a ScrollSelect or related
function is executed.
After the Component
Processor updates the database, it initiates the SavePostChange event. You can
use SavePostChange PeopleCode to update tables not in your component using the
SQLExec built-in function.
If you are executing
Workflow PeopleCode, keep in mind that if the Workflow PeopleCode fails,
SavePostChange PeopleCode is not executed. If your component has both Workflow
and SavePostChange PeopleCode, consider moving the SavePostChange PeopleCode to
SavePreChange or Workflow
PrePopup PeopleCode menu item
operations (such as HideMenuItem, EnableMenuItem, and so on) work with pop-up
menus attached to a grid, not a field in a grid, only if the PrePopup
PeopleCode meant to operate on that pop-up menu resides in the record field
that is attached to the first column in the grid. It does not matter if the
first field is visible or hidden.
·
In
applications that run on the PeopleSoft portal, external, dynamic link
information must be placed in RowInit PeopleCode.
If it's
placed in FieldChange PeopleCode, it won't work.
\SearchInit PeopleCode Function
RestrictionsYou can't use the following functions in SearchInit PeopleCode:
DoModal
DoModalComponent
Transfer
TransferPage
Populating grid and Scroll through peoplecode
This comment has been removed by the author.
ReplyDeleteQ: can we attach secondary pages to component?
ReplyDelete