NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Model Plugin - OnTheFly Step Results: Operating on AdditionalResults

Solved!
Go to solution

Hi all,

 

I've been banging my head against the wall on this and I'm wondering if anyone can help me out.

 

I'm writing a TestStand plugin that uses the "Model Plugin - OnTheFly Step Results" entry point.

What I'm trying to do is iterate over each element in Parameters.Results and check for the presence of an additional result with a specific name. Say for example, "SpecialAdditionalResult". Then I want to retrieve the value of "SpecialAdditionalResult".

 

I've gotten as far as

Parameters.Results[Locals.i].GetPropertyObject("AdditionalResults",0)

...but then once I have the property object, how do I access an additional result by name?

I'm thinking it has to be something simple that I'm missing...

 

Thanks very much,

 

Mr. Jim

 

 

 

0 Kudos
Message 1 of 3
(2,455 Views)
Solution
Accepted by topic author Mr._Jim

Try this:

 

Parameters.Results[Locals.i]->AdditionalResults[Locals.Foo]

Where Locals.Foo = SpecialAdditionalResult and is a String.  However, if it doesn't exist it will throw an error.  So you may want to do a propertyexists on it first.

 

or this will work too:

Parameters.Results[Locals.i]->AdditionalResults[Locals.j].Name

jigg
CTA, CLA
testeract.com
~Will work for kudos and/or BBQ~
Message 2 of 3
(2,435 Views)

Ah, I knew I was missing an operator! It's been too long since I've used C++.

Last night when I was staring at it too long I was thinking, "That seems to be a pointer. How do I get the thing it points to?"

 

Thanks a lot Jiggawax!

0 Kudos
Message 3 of 3
(2,410 Views)