LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

combox box strange behaviour

Hi,
I thought I could use the combo box as a string control with additional memory, helping the user when typing strings that are often used, just like in the address field of internet browsers. I wrote something like in the attached VI: each new string is added to the combo boxes string list (as far as it is not already in the list).
The stupid thing is that once I add a string beginning with a lower case "a" I can never thereafter enter something starting with a capital "A". 😞
Is this the expected behaviour? Is there maybe a property I didn't find so far, enabling and disabling case sensitivity?

Any help is appreciated.
Best regards

Arno

LabVIEW 7.1.1
Windows 2000
0 Kudos
Message 1 of 6
(3,886 Views)
I have seen some strange behaviors in the combobox with LV 7.0. There is a property which is update while typing (this is not settable while the vi is running so go to the property screen), but the Boolean appears to work in reverse.  That is that the auto complete feature works when unchecked.  With the auto complete disabled I am able to type anything in the box without any issues of cases interfering.  I was not able to look at your code because I have 7.0 sorry.
 
Paul
Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
0 Kudos
Message 2 of 6
(3,869 Views)
Dear Paul,
Thanks for the hint. You're right, and it seems to be the same in LabVIEW 7.1, that with the "update value while typing" property checked the autocomplete is disabled. That's the good news for me. But unfortunately "update while typing" means that with each key press the value change event is triggered. So far I used this event to update the combo boxes list of strings and now I get many unwanted entries... Futhermore the autocomplete in principle is a good feature. In my opinion it only should be configurable to be case sensitive.
I attached a 7.0 version of the VI.  Meanwhile I had an idea of how to circumvent the problem: I could use a string-ring combination to realize my own combo box (see my VI). Maybe you have an idea of how to extend it to have a case sensitive autocomplete 😉

Regards
Arno
0 Kudos
Message 3 of 6
(3,853 Views)
I see the problem but I don't have an easy solution.  It seems that NI should have put more options into the combobox.  One painful solution it to reimplement the combobox exactly how you want it, you can use the key down? and key repeat? events and filter them, this disables the default behavior and you can put any code in its place.  I think that this makes the code bloated and is usually not worth it.  I better work around is to use an activeX control combobox.  This might have all the features that you would need (you will have to try it out).  Try dropping the activeX control down and browse for a combobox, like the forms2.0 combobox.  The only problem here is that you will have activeX call-back functions which are not as nice or readable as the event structure.  Good ,luck
 
Paul
Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
0 Kudos
Message 4 of 6
(3,839 Views)
So far I tried to avoid any ActiveX and to use as much pure G as possible, but maybe you're right and I should give it a try...
Yesterday I downloaded the LabVIEW 8 evaluation copy and played around with the new XControls. This would also be a possibility. I still would have to handle these filter events you mentioned, but I would only have to code it once and the code would be encapsulated in the XControl's Facade.vi. I then only have to convince my boss to upgrade LabVIEW 8 Professional ...

Regards

Arno
0 Kudos
Message 5 of 6
(3,820 Views)
Yes it sounds like the Xcontrols are something I have been waiting for for a long time I want be able to upgrade to 8.0 for a few months but I have wanted a true G control with functionality what will not require additional code on a projects block diagram.  This will be nice because we will be able to greatly expand the pure G control set of labview.  ActiveX works great in labview but its interface is inconsistent with labviews G which makes code harder to follow.
 
Paul
Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
0 Kudos
Message 6 of 6
(3,811 Views)