Unchecking "Allow Undefined Strings" for System Combo Box Doesn't Work
Why will my system combo box still allow undefined strings even after unchecking "Allow Undefined Strings"?
The combo box works nicely because it allows the user to start typing in the string they want and the combo box will finish it off for them, but if you hit delete or change a letter turning it into an undefined string, the combo box will accept it.
Edit: I'm using LV 8.5
Message Edited by Sima on 01-14-2009 07:03 PM
Message Edited by Sima on 01-14-2009 07:04 PM
Attachments:
systemcombobox.vi 8 KB
I don't see the issue with Delete, but Backspace causes what I think you're seeing. If I type "a" into your example combo box, it autocompletes the "re" in the word "are". If I hit delete, nothing happens. If I type other characters, nothing happens. But, if I hit backspace, then the "re" disappears, leaving just "a". If I click outside the combo box, the a is left, and a string indicator picks this up. Thus, the combo box has allowed an undefined string.
Ouch. A little help from NI, please?
Maybe this is what "festo" was seeing here:
http://forums.ni.com/ni/board/message?board.id=170&requireLogin=False&thread.id=114297
(no offense intended I figured you were just slowing your code down... but thought it was an opportunity to stop others from starting bad habits with Next Multiple.)
Certified LabVIEW Architect
Wait for Flag / Set Flag
Separate Views from Implementation for Strict Type Defs
Similar Messages
-
Distinct dataset for selection combo box
Hi,
I have a dataset displayed on my page with paging and
dependant detail region as well as filter functions. Works like a
charm. For a visual look
here
My issue is this: To enable the filter with drop down select
list (aka combo box) shown in the picture I implemented the
following code
var transactlist_xml = new
Spry.Data.XMLDataSet("transactlist-xml.php",
"export/row",{sortOnLoad:"account",sortOrderOnLoad:"ascending",useCache:false,loadInterva l:60000});
var accounts_xml = new
Spry.Data.XMLDataSet("transactlist-xml.php",
"export/row/account",{sortOnLoad:"account",sortOrderOnLoad:"ascending",distinctOnLoad:tru e});
The first dataset selects the data for the entire list, the
second for the combo box. It works alright, but I deam it to be
very inefficient. I have to call the php script that does the data
selection twice, which means double the database load. Not good.
Since I have selected all the data I need in the first statement,
is away I can reduce the number of direct source reads and costruct
the second dataset out of the first?
I tried
var accounts_xml = transactlist_xml.distinct();
with no success, as transactist_xml has all the fields still
included, so clearly the rows will not be distinct.
Any suggestions/thougts?
Any hint is appreciated.
Hanno Schupp"How to Use The Focus Subsystem"
http://java.sun.com/docs/books/tutorial/uiswing/misc/focus.html -
Custom paint for a combo box?
Is there a document anywhere that describes all the parts you need to paint for a combo box? We have a particular need for a special presentation, but combo boxes can be rather complicated to paint all the parts correctly.
TIA!don't know of a document, but an example of a (color) modified comboBox is here
[http://forums.sun.com/thread.jspa?forumID=57&threadID=5283094]
you just have to copy all of the code (it does run) -
Hi Everyone,
Tooltip is not coming for the Combo Box in Forms 10g!! Is there any specific reason why is it not available??
With Regards,
YathishIts bug 1879328 I would think.
-
I own PSE 7 on disc. The laptop it was loaded on died. My new laptop doesn't have an optical drive so I downloaded PSE 7 from the Adobe site. It downloaded fine but I cannot start using it until I enter a S/N. The S/N on the disc box doesn't work.
Those links weren't particularly helpful to me. They convinced me to install the drivers for my USB 2.0 card, but that didn't make a difference. Still no OS X without a PRAM reset if I've dared to venture into OS 9.
It's always been my understanding that an unblessed System Folder will not be selectable in OS 9's Startup Disk control panel. My folders are blessed and healthy. Of course I'm running 9.2.2, as stated in my first message. I also frequently verify and repair my disks and permissions.
I did a verbose startup of OS X, and noticed something funny about "ATY...too old." Perhaps this problem is related? I ventured into my system.log file and there it was, repeated over and over, everytime I've booted this computer:
Aug 8 18:30:24 localhost kernel: From path: "/pci/@d/pci-ata@1/ata-4@0/disk@0:10,\mach_kernel", Waiting on <dict ID="0"><key>IOPathMatch</key><string ID="1">IODeviceTree:/pci/@d/pci-ata@1/ata-4@0/@0:10</string></dict>
Aug 8 18:30:35 localhost kernel: ROM ndrv for ATY,Rage128y is too old (0xb3383430)
Aug 8 18:30:41 localhost init: kernel security level changed from 0 to 1
Anyone know how to interpret that? Is it related to my problem? I googled it, and all I found was a web board of people arguing over whether the Apple installed stock ATI Rage video card that came in the G3's is appropriate for Panther. The Ye's have it as far as I'm concerned...as long as I leave OS 9 alone, my video is fine on this computer!
14" iBook G3 800, B&W PowerMac G3 350, Mac Classic II 16 :-P Mac OS X (10.3.9) System 7 Rocked! -
[Acrobat X Standard] The tool box doesn't work. Please help!
[Acrobat X Standard] The tool box doesn't work. Please help!
I have a Acrobat X Standard.
When I open the documents, I can't click the tool box. but when I don't open the documents, I can use the tool box.
To solve the problem,
1. reinstall the menu.
2. reboot the computer.
But, It still didn't work.
Plz help!!Was it AA X Std that you had these options in (sorry, I only have Pro)? If it was the trial (that is Pro), it may be that Std does not have to feature. Under XI at the Adobe site, there is a comparison of features between Std and Pro that might give you a hint.
There is also an option to turn on or hide many tools. For me there is a small icon just above the tools...comment titles. If you select that it give a list of tools you can display. Often, several are not displayed by default. How you lost them is another things, but it is getting them that is the basic question. -
Trying to load a downloaded version of illustrator 6cs onto new mac and the old activation code for my illustrator cs doesn't work with it. Do I need a new code or am I missing something? Same goes for my Photoshop cs.
you need your serial number.
if you purchased from or registered with adobe check your account, https://www.adobe.com/account.html -
Cinema Display (clear) with DVI/ADC box doesn't work with MacBook Pro
Cinema Display (clear) with DVI/ADC box doesn't work with MacBook Pro when plugged in with a dvi to mini dvi cable. Any ideas what to do to make it work? I lugged the 23" 2500 miles into the wilderness and I need help
Okay, here's an update: the DVI to ADC adapter does work with the Apple displays that I have tried, but it won't work with the Formac. I have tried multiple time to contact them, but to no avail... they don't even respond to threats of posting my opinion of them, which is this:
DON'T BUY ANYTHING FROM FORMAC! They make quality products, but their customer service is a big time joke! They won't take care of you. -
How can i get the video if I go on tv5 news for the moment it doesn't work!
How can I get the video if I go on tv5 news? for the moment it doesn't work!
thank you very much, I am sorry but I don't know what all this is!! I am a new apple user ... comming from PC ! I go on internet to view the news and the video doesn't appear so I suppose, like on my computer that there is something that I have to download to make it work!
-
I got an Ipod shuffle because I have two cars with USB port for mp3. It doesn't work. Can it ever?
im not shure but if you get an 3.5 mm sterio headphone jack and plug that in your car and shuffle it should work just as good
-
my ibook g4 won't start anymor from the harddisk. so I tried to reinstall the system from the orginial system cd. Doesn't work. It says the system cd is damaged. What should I do?
I would question that error message if the Mac OS X 10.5 DVD doesn't work, either.
What error message(s) did you get with the Mac OS X 10.5 DVD? Is the Mac OS X 10.5 DVD the full retail install DVD, an upgrade DVD, or a DVD that came with another Mac? -
Powershell Unique Selections for Multiple Combo Boxes
I am currently working on a powershell script that will use 4 combo box controls. I would like for them to all use the same data source whether it be an array or just a .txt file. I would like for each selection to be unique so that no 2 combo boxes can
have the same item selected. Is there a way to hide the item selected in the data source so the other combo boxes do not even have the option to select it and then when the user changes the item in one of the combo boxes the item is available again?What I am looking do do is have a list of values (T1111,T1112,T1113,T1114) to be selected from by 4 combo boxes. Each value can only be selected once so if one combo box picks T1111 the other 3 do not have that option in its selection. So far I reload the
combo boxes ever time a selection is made and remove the option from the array, but I was looking to see if there is a better way. As it currently stands, getting distinct values isn't working.
Code snippet to remove item from array:
function Get-DataSource
$array = @("T1111", "T1112", "T1113", "T1114")
$combo1 = $combobox1.SelectedItem.ToString()
$combo2 = $combobox2.SelectedItem.ToString()
$array = $array | Where-Object -FilterScript { $_ -ne $combo1 }
$array = $array | Where-Object -FilterScript { $_ -ne $combo2 }
return $array
I apologize for not uploading my code.
function OnApplicationLoad {
#Note: This function is not called in Projects
#Note: This function runs before the form is created
#Note: To get the script directory in the Packager use: Split-Path $hostinvocation.MyCommand.path
#Note: To get the console output in the Packager (Windows Mode) use: $ConsoleOutput (Type: System.Collections.ArrayList)
#Important: Form controls cannot be accessed in this function
#TODO: Add modules and custom code to validate the application load
return $true #return true for success or false for failure
function OnApplicationExit {
#Note: This function is not called in Projects
#Note: This function runs after the form is closed
#TODO: Add custom code to clean up and unload modules when the application exits
$script:ExitCode = 0 #Set the exit code for the Packager
#endregion Application Functions;2
# Generated Form Function
function Call-tenet_psf {
#region Import the Assemblies
[void][reflection.assembly]::Load('mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089')
[void][reflection.assembly]::Load('System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089')
[void][reflection.assembly]::Load('System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089')
[void][reflection.assembly]::Load('System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089')
[void][reflection.assembly]::Load('System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a')
[void][reflection.assembly]::Load('System.Xml, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089')
[void][reflection.assembly]::Load('System.DirectoryServices, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a')
[void][reflection.assembly]::Load('System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089')
[void][reflection.assembly]::Load('System.ServiceProcess, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a')
#endregion Import Assemblies
#region Generated Form Objects
[System.Windows.Forms.Application]::EnableVisualStyles()
$form1 = New-Object 'System.Windows.Forms.Form'
$combobox2 = New-Object 'System.Windows.Forms.ComboBox'
$combobox1 = New-Object 'System.Windows.Forms.ComboBox'
$buttonOK = New-Object 'System.Windows.Forms.Button'
$InitialFormWindowState = New-Object 'System.Windows.Forms.FormWindowState'
#endregion Generated Form Objects
# User Generated Script
function OnApplicationLoad {
#Note: This function is not called in Projects
#Note: This function runs before the form is created
#Note: To get the script directory in the Packager use: Split-Path $hostinvocation.MyCommand.path
#Note: To get the console output in the Packager (Windows Mode) use: $ConsoleOutput (Type: System.Collections.ArrayList)
#Important: Form controls cannot be accessed in this function
#TODO: Add modules and custom code to validate the application load
return $true #return true for success or false for failure
function OnApplicationExit {
#Note: This function is not called in Projects
#Note: This function runs after the form is closed
#TODO: Add custom code to clean up and unload modules when the application exits
$script:ExitCode = 0 #Set the exit code for the Packager
$FormEvent_Load={
#TODO: Initialize Form Controls here
Load-ComboBox $combobox1 (Get-DataSource)
Load-ComboBox $combobox2 (Get-DataSource)
function Get-DataSource
$array = @("T1111", "T1112", "T1113", "T1114")
$combo1 = $combobox1.SelectedItem.ToString()
$combo2 = $combobox2.SelectedItem.ToString()
$array = $array | Where-Object -FilterScript { $_ -ne $combo1 }
$array = $array | Where-Object -FilterScript { $_ -ne $combo2 }
return $array
#region Control Helper Functions
function Load-ComboBox
<#
.SYNOPSIS
This functions helps you load items into a ComboBox.
.DESCRIPTION
Use this function to dynamically load items into the ComboBox control.
.PARAMETER ComboBox
The ComboBox control you want to add items to.
.PARAMETER Items
The object or objects you wish to load into the ComboBox's Items collection.
.PARAMETER DisplayMember
Indicates the property to display for the items in this control.
.PARAMETER Append
Adds the item(s) to the ComboBox without clearing the Items collection.
.EXAMPLE
Load-ComboBox $combobox1 "Red", "White", "Blue"
.EXAMPLE
Load-ComboBox $combobox1 "Red" -Append
Load-ComboBox $combobox1 "White" -Append
Load-ComboBox $combobox1 "Blue" -Append
.EXAMPLE
Load-ComboBox $combobox1 (Get-Process) "ProcessName"
#>
Param (
[ValidateNotNull()]
[Parameter(Mandatory=$true)]
[System.Windows.Forms.ComboBox]$ComboBox,
[ValidateNotNull()]
[Parameter(Mandatory=$true)]
$Items,
[Parameter(Mandatory=$false)]
[string]$DisplayMember,
[switch]$Append
if(-not $Append)
$ComboBox.Items.Clear()
if($Items -is [Object[]])
$ComboBox.Items.AddRange($Items)
elseif ($Items -is [Array])
$ComboBox.BeginUpdate()
foreach($obj in $Items)
$ComboBox.Items.Add($obj)
$ComboBox.EndUpdate()
else
$ComboBox.Items.Add($Items)
$ComboBox.DisplayMember = $DisplayMember
$combobox1_SelectedIndexChanged={
#TODO: Place custom script here
Load-ComboBox $combobox2 -Items (Get-DataSource)
$combobox2_SelectedIndexChanged={
#TODO: Place custom script here
Load-ComboBox $combobox1 -Items (Get-DataSource)
# --End User Generated Script--
#region Generated Events
$Form_StateCorrection_Load=
#Correct the initial state of the form to prevent the .Net maximized form issue
$form1.WindowState = $InitialFormWindowState
$Form_Cleanup_FormClosed=
#Remove all event handlers from the controls
try
$combobox2.remove_SelectedIndexChanged($combobox2_SelectedIndexChanged)
$combobox1.remove_SelectedIndexChanged($combobox1_SelectedIndexChanged)
$form1.remove_Load($FormEvent_Load)
$form1.remove_Load($Form_StateCorrection_Load)
$form1.remove_FormClosed($Form_Cleanup_FormClosed)
catch [Exception]
#endregion Generated Events
#region Generated Form Code
$form1.SuspendLayout()
# form1
$form1.Controls.Add($combobox2)
$form1.Controls.Add($combobox1)
$form1.Controls.Add($buttonOK)
$form1.AcceptButton = $buttonOK
$form1.ClientSize = '614, 289'
$form1.FormBorderStyle = 'FixedDialog'
$form1.MaximizeBox = $False
$form1.MinimizeBox = $False
$form1.Name = "form1"
$form1.StartPosition = 'CenterScreen'
$form1.Text = "Form"
$form1.add_Load($FormEvent_Load)
# combobox2
$combobox2.FormattingEnabled = $True
$combobox2.Location = '123, 92'
$combobox2.Name = "combobox2"
$combobox2.Size = '121, 21'
$combobox2.TabIndex = 2
$combobox2.add_SelectedIndexChanged($combobox2_SelectedIndexChanged)
# combobox1
$combobox1.FormattingEnabled = $True
$combobox1.Location = '123, 64'
$combobox1.Name = "combobox1"
$combobox1.Size = '121, 21'
$combobox1.TabIndex = 1
$combobox1.add_SelectedIndexChanged($combobox1_SelectedIndexChanged)
# buttonOK
$buttonOK.Anchor = 'Bottom, Right'
$buttonOK.DialogResult = 'OK'
$buttonOK.Location = '140, 254'
$buttonOK.Name = "buttonOK"
$buttonOK.Size = '75, 23'
$buttonOK.TabIndex = 0
$buttonOK.Text = "&OK"
$buttonOK.UseVisualStyleBackColor = $True
$form1.ResumeLayout()
#endregion Generated Form Code
#Save the initial state of the form
$InitialFormWindowState = $form1.WindowState
#Init the OnLoad event to correct the initial state of the form
$form1.add_Load($Form_StateCorrection_Load)
#Clean up the control events
$form1.add_FormClosed($Form_Cleanup_FormClosed)
#Show the Form
return $form1.ShowDialog()
} #End Function
#Call OnApplicationLoad to initialize
if((OnApplicationLoad) -eq $true)
#Call the form
Call-tenet_psf | Out-Null
#Perform cleanup
OnApplicationExit -
Need guidance for a Combo Box and Keystoke/Validate script
Hello,
My goal is to have a combo box selection trigger and enter a value into a text field however the text field needs to be editable. I want the combo box to determine a default value but changeable by the user if necessary. Here is the script, I just don't know where to put it.
if (!event.willCommit) {
var M1Month = this.getField("Month 1 Pulldown").value; var M1Exp = this.getField("M1 Exp");
if(M1Month == "January") {M1Exp.value = "1/31/10"};
if(M1Month == "February") {M1Exp.value = "2/28/10"};
if(M1Month == "March") {M1Exp.value = "3/31/10"};
if(M1Month == "April") {M1Exp.value = "4/30/10"};
if(M1Month == "May") {M1Exp.value = "5/31/10"};
if(M1Month == "June") {M1Exp.value = "6/30/10"};
if(M1Month == "July") {M1Exp.value = "7/31/10"};
if(M1Month == "August") {M1Exp.value = "8/31/10"};
if(M1Month == "September") {M1Exp.value = "9/30/10"};
if(M1Month == "October") {M1Exp.value = "10/31/10"};
if(M1Month == "November") {M1Exp.value = "11/30/10"};
if(M1Month == "December") {M1Exp.value = "12/31/10"};
if(M1Month == " ") {M1Exp.value = ""};I did not say to take out the line. You need to replace the "" (a null string), with " " (a space).
But I would look at using the 'switch' statement that allows for a series of logical test and if none of those specific test has been passed takes a default action.
You need to put the script in the 'Custom keystroke script'.
if (!event.willCommit) {
var M1Exp = this.getField("M1 Exp");
if(event.changeEx == "January") {
M1Exp.value = "1/31/10";
} else if(event.changeEx == "February") {
M1Exp.value = "2/28/10";
} else if(event.changeEx == "March") {
M1Exp.value = "3/31/10";
} else if(event.changeEx == "April") {
M1Exp.value = "4/30/10";
} else if(event.changeEx == "May") {
M1Exp.value = "5/31/10";
} else if(event.changeEx == "June") {
M1Exp.value = "6/30/10";
}else if(event.changeEx == "July") {
M1Exp.value = "7/31/10";
} else if(event.changeEx == "August") {
M1Exp.value = "8/31/10";
} else if(event.changeEx == "September") {
M1Exp.value = "9/30/10";
}else if(event.changeEx == "October") {
M1Exp.value = "10/31/10";
}else if(event.changeEx == "November") {
M1Exp.value = "11/30/10";
}else if(event.changeEx == "December") {
M1Exp.value = "12/31/10";
}else{
// all other selections
M1Exp.value = "";
} // end not will commit
You will also need to use the 'event' object's 'changeEx' property.
If you do not need the selected text, by setting the export value to the expiration date your script could be:
if (!event.willCommit) {
this.getField("M1 Exp").value = event.changeEx; -
Input Controls - is it possible to change the font for a combo box
I have an input Control combo box that is a mixture of english/chinese characters. In Webi I can view the chinese characters correctly if I change the font to MingLIU. Is it possible to change the font for an input control OR to set a default font?
I am a first-time user of the photo book application in iPhoto.
I also was a first-time user, so I started using it. Exploring the possibilities, learning my way around.
Thanks, in advance, for any suggestions someone might have.
Click the ? icon
Oops. Sorry, but you're in the wrong forum : iLife > iPhoto -
CUIT is not giving name property value for VB combo boxes
Hi Everyone,
We are testing simple Vb6 controls using CUIT. Using CUIT we can get name property value of Vb6 button control. But for simple Vb6 combo box, CUIT is not showing name property value.
I want to add CUIT assertion for combo box name property value. how can I add ?
For more details please see the image
Regards,
Rajendar..Hi Rajendar,
Do you record a coded UI test with the coded UI test builder? If so, which item did you record?
>>How can I get combobox.SelectedItem without identifying combo box?
It doesn't mean that we don't identify the control. Generally we use the unique property as the search property to find/capture the control.
Like this blog here:
http://blogs.msdn.com/b/visualstudioalm/archive/2012/02/01/guidelines-on-improving-performance-of-coded-ui-test-playback.aspx
SelectedItems versus
SelectedIndices property
For large number of items, it is preferable to use SelectedItems. SelectedIndices essentially does an Instance search internally, which is slower compared to unique automation property based search. Use SelectedIndices only when
the items don’t have unique Automation properties. And of course exercise caution over changes to the list content.
I think you could get a useful sample here:
https://social.msdn.microsoft.com/Forums/vstudio/en-US/a32bc4a6-f562-436d-96a4-a3409b1b3e73/codedui-and-combobox-i-want-to-go-to-the-next-nonselected-item-in-combobox?forum=vstest
Best Regards,
Jack
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey.
Maybe you are looking for
-
Table Header in freezed pane when exporting SSRS report to Excel
Hi, I want table Header in freezed pane when exporting SSRS report to Excel. Can I have the table header of tablix be present in freezed pane of excel. Thanks, Vivek Singh
-
I believe that my iPhone or apple ID has been hacked into. Three imessages were sent from my phone that I did not type or send - two while I was asleep at 1:15am and in the morning during an iMessage conversation. These messages were to my boyfrien
-
I created a responsive project with a demo in Captivate 8 that includes a full motion recording. When I preview it, I can see the non-fmr slides, but the fmr is just showing a white screen. What's up with that? Darin
-
Working on PPro CS4 footage/project in AE CS4
Hi Everyone, I'm new to this particular forum, so please be gentle! I have shot some video that I want to stabilise in AE, so I went into Premiere and chose my best clips and shortened some clips to a second or so longer than they need to be (at the
-
Content Management in Portal How to
Hi, I´m Learning XML Forms but I have red that it is too static and I was wondering how do we manage content within Portal and KM? is there another tool to create and deploy content within the Portal? or it has to be developed and called from an iVie