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 6 Next »

The string.checkReverse() method returns the last position in a string that contains a character, which does not appear in the comparator.

 

Parameters

  1. Comparator
  2. Start Index

Examples

pjs.define("c1", { type: 'char', length: 50 });
pjs.define("num", { type: 'packed decimal', length: 2, decimals: 0 });

c1 = 'My *dog* Spot.* @ * @ *';
num = c1.checkReverse(' *@');

return num;
//14
pjs.define("c1", { type: 'char', length: 6, initValue: '$2000.' });
pjs.define("num", { type: 'integer', length: 5, decimals: 0 });

num = c1.checkReverse('0123456789', 5);

return num;
//1

 

 

RPG Equivalent

%CHECKR()

  • No labels