Skip to content

$p.getGridCell

Overview

This explains the method to get the elements of the td tag on the "Screen Index".

Syntax

JavaScript
$p.getGridCell(Record ID,' Name displayed on index record')

Usage Examples

After setting the following sample code to the Pleasanter script and setting the output destination to "Edit", if a record with record ID: 123 exists when the Screen Index is loaded, the title of that record will be displayed at the bottom of the screen.

JavaScript
$p.events.on_grid_load = function () {
    $p.clearMessage();
    $p.setMessage('#Message', JSON.stringify({
        Css: 'alert-success',
        Text: $p.getGridCell(123, 'Title/Content')[0].textContent
    }));
}