Measurement Studio for VC++

cancel
Showing results for 
Search instead for 
Did you mean: 

CNiNumedit and Time

Hello everybody,

 

is it possible to enter a time in format hour:minutes:secondes greater than23:59:59 in an CNiNumEdit?

 

A formatstring like hhh:nn:ss didn´t work, but hhh:nn:ss worked with CniGraph for the timeaxis.

 

The result is onley cwui-error: Type missmatch if i try to enter e.g. 25:0:0

 

Kind regards

 

Swen Habenberger

0 Kudos
Message 1 of 5
(7,432 Views)

Hello Swen,

 

I just opened the example "Simple Numeric" for VC++ 2005 and Measurement Studio 8.5, opened the dialog resource, changed the format string for the time display NumEdit control to hhh:nn:ss, ran the example, and it showed values above 23:59:59. If you run this example, are you able to see the same results as me?




NickB

National Instruments 

Message Edited by nickb on 10-29-2008 01:53 PM
0 Kudos
Message 2 of 5
(7,392 Views)

Yes, I can see the same results. But, if i use the CniNumedit as a Control, not as an indicator and i try to change time directly in the Control to a time greater than 24:0:0 i get the error cwui error: Type mismatch.

Editing times between  0:0:0 and 23:59:59 works fine for me. 

Message Edited by swen on 10-30-2008 03:05 AM
0 Kudos
Message 3 of 5
(7,381 Views)

Hello Swen,

 

Sorry to have taken so long to get back to you. I just wanted to let you know that this has been reported for investigation with CAR ID 132143.  Thanks for the feedback.

 

NickB

National Instruments 

0 Kudos
Message 4 of 5
(7,335 Views)

Hello Swen,

 

I just wanted to let you and the rest of the community know the preliminary results of the our investigation into the issue you have raised...  Officially, the CWNumEdit's FormatString does not support entering time values greater than 23:59:59. 

 

However, as seen in the example I referenced above, if you start below 23:59:59, and use "hhh" as the string format, you can incrementally go above that value, which may be the starting point of a workaround for you.  However, because "hhh" is not a supported format string, and is not documented as such in the help, it is important to note that the results can be a little bit strange, and this workaround is only to be used at your own caution.

 

In the future, we hope to change the error message to read something similar to "Invalid Input", which will be a little less ambiguous than "Type Mismatch".  We also will explicitly document that anything above 23:59:59 is not supported.

 

I'm sorry for any trouble that this may have caused you.

 

NickB

National Instruments 

 

0 Kudos
Message 5 of 5
(7,248 Views)