With the new Sequencer Object is it possible to give the Sequencer a starting number similar to using the original seqencer workspace item?
Solved! Go to Solution.
Solved by dvirh. Go to Solution.
Yes, it is possible to do that.
When creating the sequencer object, use the following format
var seq = new Sequencer(seqName[, start[, step]]);
The Start is the start number you want to give to the sequencer, and the Step is the increment that you want the sequencer to jump by. Note that Start and Step are optional. Note also that if you include Start and Step, you must always use the same Start and Step value for the same Named Sequencer. You can't use this command to change the Start or Step value of an existing sequencer. If you use a different Start and/or Step values when setting up the sequencer, the function may ignore the new Start and Step numbers or may even fail. However, you may ommit the Start and Step numbers following the initial creation of a new sequencer
Understood, I missed the signifigance of the Start option.
Now the question is where are the sequencers stored? It appears that you should be able to get a list of existing sequencers in your tenant using the Sequencer object and the list method, but I can't seem to get it to work. I did try looping through the Sequencer object but still got nothing.
Syntak I am using
var Seqlist = Sequencer();
println(Seqlist.list())
This didn't produce any errors but the debug output did not give what I would have expected from an array
Debug output - [Lcom.dms.scripting.scriptables.SequencerScriptable;@1b6e732d
I am assuming this object is not looking at the Sequencer workspace.
Thanks
BD
You are pretty close! Here is the correct syntax:
var seqNameArray = Sequencer.list();
In other words, you don't need to create a sequencer object first and then access the list, you can directly ask for the list using the syntax above.