Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 7 Current »

Content Freeze

As of July 25th, 2023, there is a content freeze on this page.

The pjs.reset() API can be used to reset the contents of a field, an array, or a data structure to its initial value.

Parameters
  • Field, array, or data structure
Example
  pjs.define("DS1", { type: 'data structure', qualified: true, elements: {
    "Day1": { type: 'char', length: 6, initValue: 'MONDAY' },
    "Day2": { type: 'char', length: 8, initValue: 'TUESDAY' },
    "JDate": { type: 'char', length: 8, initValue: '010101' }
  }});

  DS1.Day1 = 'FRIDAY';

  pjs.reset(DS1);  // DS1.Day1 is now 'MONDAY' again

RPG Equivalent 

RESET

  • No labels