NI Home
Cart Cart | Help
Hello Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI
You are here: 
NI Home > NI Developer Zone > NI Discussion Forums


Reply
Member
sahin
Posts: 30
0 Kudos

entering numeric values with suffixes in Labwindows CVI (e.g 100 kHz instead of 100e3 or 100000 )

is there any practical way of entering numeric values with suffixes in Labwindows CVI in order to prevent user from struggling with '0' es. 

 

Active Participant
Wolfgang
Posts: 1,926
0 Kudos

Re: entering numeric values with suffixes in Labwindows CVI (e.g 100 kHz instead of 100e3 or 100000 )

Hi,

 

one simple way might be to change the label from Hz to kHz, enter only 100 instead of 1e5, and multiply the value obtained from the numeric control by 1000 for further use in your program...

Member
sahin
Posts: 30
0 Kudos

Re: entering numeric values with suffixes in Labwindows CVI (e.g 100 kHz instead of 100e3 or 100000 )

thanks:smileyhappy:

but i meant entering 100kHz or 1Ghz directly to the numeric control but it is not possible to enter a letter in numeric control.

taking 1000 Hz as reference doesn't solve the problem for  entries with unit 'mega' or 'giga' hertz, and also entries with unit Hz again will be

shown with 'engineering form' in the numeric control.

Active Participant
Wolfgang
Posts: 1,926
0 Kudos

Re: entering numeric values with suffixes in Labwindows CVI (e.g 100 kHz instead of 100e3 or 100000 )

So what you could do is using two adjacent controls, a numeric and e.g. a ring or text control where the user can select or enter the unit: Hz/kHz/MHz/GHz. Another option could be to use a string control instead of the numeric control and parse the entered string; however the string control lacks the up/down arrows...

Active Participant vix
Active Participant
vix
Posts: 515
0 Kudos

Re: entering numeric values with suffixes in Labwindows CVI (e.g 100 kHz instead of 100e3 or 100000 )

In LabVIEW there is another Display Format called "SI Notation" that is exactly what you're looking for.

Maybe you can add a feature request in CVI Idea Exchange Forum and ask NI to add this Display Format in CVI too.

Vix
-------------------------------------------
In claris non fit interpretatio

-------------------------------------------
Using LV 2011 SP1 on Win 7 64bit
Using LV 8.2.1 and 6.1 on WinXP SP3
Using LV 6.1 on Linux openSUSE 10.2
Using CVI 2010 SP1 on Win 7 64bit, WinXP and WinXP Embedded
Using CVI 6.0 on Win2k, WinXP and WinXP Embedded
By using this web site, you accept the Terms of Use for this web site. Please read these Terms of Use carefully before using any part of this site. Please go here for information on ni.com's copyright infringement policy.
My Profile | Privacy | Legal | Contact NI © 2011 National Instruments Corporation. All rights reserved.    |    E-Mail this Page E-Mail this Page