Using the Analytic Grid in PeopleCode
The PeopleCode AnalyticGrid object is a reference to a page runtime object for the analytic grid. These particular page runtime objects aren’t present until the component is started.
Note: PeopleSoft builds a page grid one row at a time. Because the AnalyticGrid class applies to a complete grid, you can’t attach PeopleCode that uses the AnalyticGrid class to events that occur before the grid is built; the earliest event you can use is the page Activate Event.
If you’re using the analytic grid within a secondary page, the runtime object for the grid isn’t created until the secondary page is run. The grid object can’t be obtained until then, which means that the earliest PeopleCode event you can use to activate a grid that’s on a secondary page is the Activate event for the secondary page.
The attributes you set for displaying an analytic grid remain in effect only while the page is active. When you switch between pages in a component, you have to reapply those changes every time the page is displayed.
In addition, the Activate event associated with a page fires every time the page is displayed. Any PeopleCode associated with that Activate event runs, which may undo the changes you made when the page was last active. For example, if you hide a grid column in the Activate event, then display it as part of a user action, when the user tabs to another page in the component, then tabs back, the Activate event runs again, hiding the grid column again.
If a user at runtime hides a column of a grid, tabs to another page in the component, then tabs back to the first page, the page is refreshed and the grid column is displayed again.
You can use the rowset class methods and properties on analytic grid data. You can access the data loaded by the analytic grid by accessing a rowset object after the grid is populated.
Use the analytic grid classes to manipulate the display of an analytic grid—that is, one associated with PeopleSoft Analytic Calculation Engine data. If you want to manipulate a grid control, use the grid classes.