08-18-2011 11:54 PM
Hi,
i need to add customized "stepid" for each step .
how can i do that .
can some one please help me in this regards.
Thanks
IVI
08-19-2011 02:21 AM
IVI,
since you do not state what this custom step ID is used for, i am only guessing:
Take a look into "Requirements".
hope this helps,
Norbert
08-19-2011 03:03 AM
Hi,
thanks for your response.
i need to display the TestID in my report file.
but i dont want to touch my report module.
i hope the testId are autogenrated for eachstep.
is there a way i can give my own testID for each step?
Thanks
IVI
08-19-2011 03:06 AM
IVI,
if you use Requirements for your ID, you can add that info using "Additional Results". Requirements is a preconfigured selection there....
Norbert
08-19-2011 03:12 AM
My report module is a preconfigured one , am not allowd to change it.
it will take ID from TestID feild i canot change it to take from Requirment feild.
is there a way i can change the ID property value to my desired value.
Thanks
IVI
08-19-2011 03:25 AM
IVI,
i don't understand what you are currently doing. It seems to me, that you are meddling with the Step.ID property. This is highly NOT recommended. There is a reason why this property is hidden!
My proposal is to enter the custom ID you are trying to apply to into the requirements section for each step and add it to the report. For this, open the sequence in the NI Sequence Editor, select the step, switch to the "Requirements" tab, enter your ID as requirement. Switch (in the same step) to the "Additional Results" tab and select "Requirements" as additional result.
With this, you are not going to change anything in the report settings.
Give it a try,
Norbert
08-19-2011 03:27 AM
got it !!!!
thanks a lot!!!
-IVI
08-19-2011 06:10 AM
Hi,
am using the following code to get the requirmentsID from result container in my code.
stepPropertyObject.GetValString("Result.AdditionalResults[Requirements]", 0);
But am not able to read the value its returning error.
is the expression correct to get the Additonalresults?
Thanks
IVI
08-19-2011 06:24 AM
IVI,
where do you try to access this value? And why?
Well, if you want to access the additional result from the ResultList, you will have to use something like this:
Locals.ResultList[0].AdditionalResults["Requirements"]
If you want to use it as 'external' lookup string, you have to remember escape characters, so the string would look like this:
"Locals.ResultList[0].AdditionalResults[\"Requirements\"]"
I hope you see the difference....
Norbert
08-19-2011 06:59 AM
Hi,
am using the followwing code
voidaxApplicationMgr_UIMessageEvent(objectsender,NationalInstruments.TestStand.Interop.UI.Ax._ApplicationMgrEvents_UIMessageEventEvente)
{
if (e.uiMsg.Event ==UIMessageCodes.UIMsg_Trace)
{
try
{
intframeid;
SequenceContext seqctx = e.uiMsg.Thread.GetSequenceContext(0, outframeid);
if(seqctx.PreviousStepIndex >= 0)
{
Stepprvstp = seqctx.PreviousStep;
StepTypeprvstptyp = prvstp.StepType;
PropertyObjectstepPropertyObject = prvstp.AsPropertyObject();
String testid=String.Empty;
if (string.Equals(prvstptyp.Name, "NumericLimitTest"))
{
testid = stepPropertyObject.GetValString("Result.AdditionalResults[\"Requirements\"]", 0);
double lwlimt = stepPropertyObject.GetValNumber("Limits.Low", 0);
double measValue = stepPropertyObject.GetValNumber("Result.Numeric", 0);
String unit = stepPropertyObject.GetValString("Result.Units", 0);
am not able to read the Requirments by "testid = stepPropertyObject.GetValString("Result.AdditionalResults[\"Requirements\"]", 0);"
but am sucessful in reading all others.
can you please help me in this regards.
Thanks
IVI