This topic is locked

AUTOINCERMENTAL

1/6/2012 9:57:42 AM
PHPRunner General questions
B
bujar.gashi author

Can anyone help me how to Auto increment alpha numeric by php script in phprunner6 :

for example RKS-DKK-001 so number 001 to be changet after every new add (001 , 002 ,....006 ).

C
cgphp 1/6/2012

You can increment the string directly:

$token = 'RKS-DKK-001';

$token++;


When the numeric chunk reaches 999 the count restart from zero (000). If you need more control over this process you have to parse the string.

B
bujar.gashi author 1/6/2012

Thanks Cristian ,
so how can i use this string on (after record added ) on phpruuner, cose im begenner on php ?

thnka sin adwanse



You can increment the string directly:

$token = 'RKS-DKK-001';

$token++;


When the numeric chunk reaches 999 the count restart from zero (000). If you need more control over this process you have to parse the string.