LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Multiple Numeric - renaming the Step.Result.Measurement[0]

Hi,

I would like to dynamically rename, in CVI:

Step.Result.Measurement

[0] 

[1] 

...

[N-1] 

 

to :

Step.Result.Measurement

[0] abc

[1] abc

...

[N-1] abc

 

Does anyone know the CVI command for this?

ie default - there is no name.

I would like to attach a name to each step.

 

Thanks,

Shmuel

0 Kudos
Message 1 of 5
(2,506 Views)

Hi,

As far as I can tell, Step.Result.Measurement is a function in TestStand. Have you posted on the TestStand forums? You might have better luck there. 

0 Kudos
Message 2 of 5
(2,467 Views)

Hi Zofia,

Thanks for your reply.

I didn't post there as I was looking for the CVI code, that why I posted here ....

In any case, eventually I found a post addressing the issue, by a Ryan Ramcharan, dated 15/7/2002, I think a app engineer form NI !! Not sure how to forward the post, so I will copy here, and other that may encounter the same problem can search for it more easily. His response to "April", certainly helped, it was spot on and it worked well for me.

 

All the best,

Shmuel

 

===========================================================

 

Re: Measurement Name Access for Multiple Numeric Limits Test in TestStand 2.0
Hello April,

You can indeed access the name property programatically. To this, you must get a Property Object reference to the Step.Result.Measurements[x] property (where x is the measurement index). You can then use the "Name" property of the Property Object class to determine or set the name of the measurement. Alternatively, you can get the Step.Result.Measurement array as a Property Object then use the GetPropertyObjectByOffset method to access an individual element of the array. Once you have a reference to this individual element, you can the use the PropertyObject "Name" property to set or get this value. The code looks someting like this:

// Line 1
errChk(TS_PropertyGetPropertyObject (testData->seqContextCVI, &errorInfo,"Step.Result.Measurem
ent", 0, &MeasObj));

// Line 2
errChk(TS_PropertyGetPropertyObjectByOffset (MeasObj, &errorInfo, 2, 0, &SpecifcMeas));

// Line 3
erChk(TS_PropertySetProperty (SpecifcMeas, &errorInfo, TS_PropertyName, CAVT_CSTRING, "NewValue"));

Hope this helps! 
 

 

0 Kudos
Message 3 of 5
(2,462 Views)

Hi Shmuel,

I'm glad you found the solution! I hope you have a happy new year!

0 Kudos
Message 4 of 5
(2,441 Views)

Thanks Zofia,

You should have a prosperous and successful new year.

Shmuel

0 Kudos
Message 5 of 5
(2,437 Views)