Iterator count is off by 1
I've created a "main" script that calls to 2 scripts that I've created. The first script has a datapool associated with it then creates a datapool during runtime for the second script to use. So the second script does not have a datapool associated with it. The script just calls to the datapool file and adds/pulls data from it. The problem I'm running into is, when I have the "main" script run and select to have the script run two times, the second script is not recognizing the iterator count to be the same as the first script on the second pass. The iterator count becomes '3' after running through the first script on the second pass. Is there a way to set the iterator count to be the same as the first script?
Use dpReset to reset the iterator.
Thanks and Regards,
Last edited by sathish804; 06-20-2013 at 02:48 AM.
Thanks sathish804 for the quick reply! However, I've put the dpReset() in my scripts in various places and always get back "CRFCN0020W: No datapool has been initialized for this script". I've even put the dpReset() right after I initialized the datapool and still get the same error.
I added dpReset() to my script before I initialized it and did not receive the error. But, the iterator count is still not correct.
Last edited by mdreicha; 06-20-2013 at 12:03 PM.
If anyone is having the same issue, I added dpNext() to the end of my second script and it worked. I guess since the second script didn't have a datapool associated with it, the iterator needs to be increment ahead programmatically.
Last edited by mdreicha; 06-21-2013 at 06:17 AM.