09-06-2010 03:08 AM - edited 09-06-2010 03:10 AM
Hi
I have some SequenceFile librarys which i like to improve for more easy of use.
Most of my librarys are using parameters to descripe what should be done.
I have realized that often things have to done twice.
At first you select a SequenceCall StepType and give a name to it. Normally it descripes
what Sequence is doing. Then you have to set your parameters values. In a lot of
cases Step.Name and Parameters where in relation. There are some possbilities to change the Step.Name
during runtime. But what about editime ?
I assume i have to create my own StepType which is derived from Ni SequenceCall StypType. I think thats not the
major problem. The main question is: Is it possible to rename it to my needs and force it to update in Sequence Editor
Regards
Juergen
Solved! Go to Solution.
09-06-2010 04:10 AM
Hi Juergen,
You are correct in that you would have to create your Step Types,
Check out on the the following TestStand Series documents here For Custom Step Types
It's been awhile since I have done this, but you will need to change the Default Step Name Expression to give you want you require.
09-06-2010 06:20 AM
Hi Ray,
Thanks for your Reply.
After writing my post i did some tests. I have realized that there is no code for the Step Type SequenceCall is available.
I think the reason is that SequenceCall is not a module is an adapter. So there is no substep function "edit".
Default Step Name could be a solution, if i will have access on the parameter list.
But what happens if Parameters where changed will be Name updated, too ?
Regards
Juergen
09-06-2010 09:04 AM
Juergen,
the edit substep is imho the way to go. I haven't looked into the needed steps to configure the "module" (aka sequence in this case), but here is what you need to do as last steps (pseudocode):
Set step.Name to desired value;
Get SequenceFile;
SequenceFile.IncChangeCount();
You can find the useful hint here. I tested this with TS 4.2.1 and it works as desired.
hope this helps,
Norbert
09-06-2010 10:06 AM
09-06-2010 10:13 AM
Juergen,
maybe you should post your current edit substep module for further hints....
Norbert
09-06-2010 10:15 AM
09-07-2010 10:17 AM
Hi Juergen,
Is there a reason why you are not using the Step Type Step Description Expression to display this information instead of the step name? The description was designed for displaying these sorts of things and is updated more dynamically than the name. The description field can be modified by modifying the Step Decription Expression on the General tab of the Step Type Properties dialog box. It is limited to what you can do in an expression, but with API in expressions and the comma to create combined expressions (the last expression is the result of the entire expression) you can do quite a lot from an expression.
Hope this helps,
-Doug
09-08-2010 02:08 AM
Hi Doug
good question. I agree that desciption would be the first choise for doing this. But for my task there is no need for the description field.
For my stuff it is more important to have a link between Sequence and Report. And this is the Step.Name. If some thing went wrong.
You are looking a the report. Remember the Step.Name and try to find in the Sequence. I am of the opinion the Step.Name descripes your
Task,Requierement or what you think the system should do. On the other hand Step.Description is telling you what system is doing.
At the moment i am in a project where i have created some sequence(files) librarys. In inside the sequences there is all what i have learned about
Teststand. No beginner will understand whats going on there. So i have designed some sequences where you can define with parameters
what the system should do. I have realized that my Paramters and Step.Name are in relation.
At the moment you have to do things twice, Change parameters values and rename step in the same way.
I like to this only once. And get rid of ts programming errors. How often i only changed only one. After system was running -> "Red"
-> reading report -> Oh man what are doing !! -> enter the forgotten second value -> system running -> green!
Regards
Juergen
09-08-2010 02:59 AM - edited 09-08-2010 03:01 AM
Hi,
Could you use the Custom substep name OnNewStep which could build your Step Name when you first insert your step.
check out this link