Restrict selecting multiple items across two ListBoxes
Hello,
I'd like to know, how to restrict user from selecting multiple items across two different ListBoxes.
Reason I need this is I want to pass that selected item forward using only one button.
Something like
if Lb_Regular.hasSelected = true then
passfunction(Lb_Regular.SelectedItem)
elseif Lb_Patch.hasSelected = true then
passfunction(Lb_Patch.SelectedItem)
else
Debug.WriteLine("Nothing is selected")
Thanks in advance,
TheCreepySheep
Hi,
You can try it like this.
Public Class Form1
Private Sub ListBox1_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles ListBox1.SelectedIndexChanged
If ActiveControl Is ListBox1 Then
ListBox2.SelectedIndex = -1
End If
End Sub
Private Sub ListBox2_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles ListBox2.SelectedIndexChanged
If ActiveControl Is ListBox2 Then
ListBox1.SelectedIndex = -1
End If
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If ListBox1.SelectedIndex > -1 Then
MessageBox.Show("Listbox1 has item selected - " & ListBox1.SelectedItem.ToString)
ElseIf ListBox2.SelectedIndex > -1 Then
MessageBox.Show("Listbox2 has item selected - " & ListBox2.SelectedItem.ToString)
Else
MessageBox.Show("No Item Is Selectd")
End If
End Sub
End Class
If you say it can`t be done then i`ll try it
Thanks! Just what I wanted!
Similar Messages
-
Selecting multiple items in a listbox
Is it possible to select multiple items in a listbox and insert them into an array. Currently, to get around not knowing if this is possible, I have two listboxes. One has items available and the other has items you want to use. I can either double click or press an add/remove button to move items between the two listboxes. The problem there is that when I move an item from one to the other it puts it at the end of the list. I want to keep the lists in order by channel. My items structure is as follows: "'channel number' 'Channel name'" ie "1 Date\Time"
I can sort this list but it sorts by the first character. If I have channels 1-30. It sorts to 1,11,12,13,14,...,3,30. I want 1,2,3,...,30 I would prefer to select multiple items in the listbox but if I can't, how can I do a better sort with my current method of two listboxes.
Thanks,
AJLHi together,
Since there is no multiple selection in Enumlistbox in SUD dialog, i wanted to use a table.
But i couldnt get the table to show the values from a user variable definition file (dynamic enumeration list). I fail to assign one column of the table to that user variable.
Below i attach the corresponding files:
where could be the problem?
And i was looking through DIAdem help file to look for information, how to define different types of user variables (for example vectors) but i couldnt find enough information. Do you have any document or examples where i can see the defining and usage of different type variables in different controls in SUD dialogs ?
thanks in advance
kaan
Attachments:
dynamic_enumeration_for_table.zip 2 KB -
Why can I not select multiple items in Muse using Shift Click after installing update?
I am trying to select multiple items on a Muse page by holding shift and clicking each items. This has been pretty much my standard method across Adobe products but after updating Muse it will no longer let me do this. Am I missing something or did this method change with the update?
It seems to be happening mostly for Hotmail account. I just rebooted and tested two accounts. Only in Hotmail now.
-
Selecting multiple items quickly in icon view
The Finder's Help menu shows only one way to select multiple items that are next to each other:
Select multiple items that are next to each other
Do one of the following:
Click one item, and then press the Shift key and click other items to include them in the selection.
Click the first item, and then press the Shift key and click the last item. All items in between are included in the selection.
Click a window to make it active, and then press Command (⌘)-A. All items in the window are selected.
When you have selected multiple items and want to deselect one of them, press the Command key and click the item.
However, I often view folders in icon view and the second method above doesn't work--frustrating if you have more than a few items.
There are two ways that do:
Change the view to List and use the second method described above (Click the first item, and then press the Shift key and click the last item) or
Click outside of the first folder/icon you wish to select, then hold and drag over the row or area:
Hope this is helpful; it would be a useful addition to the Help menu!
(Oops, just found an older similar post...sorry for the duplication.)
Message was edited by: dexterinaThanks for clarification Rhys.
I am using slicers at moment to do multi-selects but was just thinking I was missing something in case of tiles but your reply suggests that this behaviour is by design.
Nitesh Rai- Please mark the post as answered if it answers your question -
Select multiple objects across pages (cs3)
Hi
Is it possible to select multiple objects across pages? All objects have an object style attache and have to be moved 0,7 mm to up. Maybe with a script?
thanx
SOK, the move part was much easier than I had anticipated. I think I was thinking of moving graphics inside a frame (or did they just make it a lot easier in CS3?).
At any rate, this one does every page in the document. Just change "test" and the move amount to your preferences...
tell application "Adobe InDesign CS3"
tell active document
set myObjectStyle to object style "test"
repeat with i from 1 to count every page
tell page i
select (every item of all page items whose applied object style = myObjectStyle)
end tell
move selection by {0, "-0p7"}
end repeat
end tell
end tell -
How to select multiple values from a listbox
Hi,
I have a list box on my UI which is not allowing me to select multiple values
I want to use multi select list box .. When i go to source of UI component and change that to select many listbox my page is not rendering it is giving error
When i drag & drop the component i am unable to drop it as a multi select list box that option is not coming.
I am working on Jdev 11.1.1.3 and I am using ADF/BC components
How to select multiple values from a listbox ?
Thanks,Hi,
I want to use multi select list box .. When i go to source of UI component and change that to select many listbox my page is not rendering it is giving errorank
And what is the error ?
Frank -
How do you select and move more than one bookmark at a time?
Shift+Click does not select multiple items that are next to one another in a list because the items open in firefox before this happens.Use the bookmarks library. You may use Shift +Click, and Ctrl + Click to create groupings of selected bookmarks to drag and drop.
* one method of opening the bookmarks library is keyboard shortcut <br /> Ctrl+Shift+B (Windows)
*see also [[How to use bookmarks to save and organize your favorite websites]]
*and [[Use bookmark folders to organize your bookmarks]] -
How do I select multiple items?
Happy New Year. I am a new Mac user. Recently switched from Windows. How do I select multiple rows? In windows you can CONTROL+click to select multiple items 1 at a time and SHIFT+click to select multiple items in groups. I figured out to do COMMAND+click on Mac to select multiples 1 at a time. I need to delete ALOT of rows. How do I select multiples in groups?
Thanks.KarenSelena and BobHarris have given you the direct sequences.
You can also select multiple disjoint ranges with combinations of ⌘ (command key) click and ⇑ (shift key) click, too.
As you use OS X, you'll find a large number of ⌘ and ⇑ and ˄ (control key) and ⌥ (option key) clicks and shortcuts available (and some were mentioned earlier), and shortcuts such as ⌘ A (select all), ⌘ Z (undo) and a whole host of other shortcuts available.
Here is Apple's Mac 101 / Mac Basics site, which has a good (and free) introduction toward learning to use your Mac. -
I have recently changed from Windows 7 desktop to a new iMac running Mavericks. I have chosen a wired keyboard as I like the usual Delete key function.
I cannot find out how to select several items which are not next to each other (e.g. words in Pages). The well known method in Windows, which is repeated in the the Apple Finder Help screen, does not work. Would be grateful for adviceHi JBowfin,
If I am understanding your question correctly, I believe that I have an article that will address this question for you:
Mac OS X 10.0: Use Command Key to Select Multiple Items in List and Column Views
http://support.apple.com/kb/TA20396
Take care, and thanks for visiting the Apple Support Communities.
-Braden -
Hi Everyone
Please advise: how do I select multiple items when on Safari? Ex. when I have to select multiple countries where I have worked.Hi Carolyn
I am trying to select multiple items from a list on a particular website. I tried using the 'command' button, but to no avail.
Grateful for any advice. -
when editing info, how do i select multiple items to edit a group? For example, changing the artist name on multiple tracks at once?
Same way you select multipl items anywhere else.
Hold ctrl and click the items you want.
If they are in consecutive order, click the 1st then Shift click the last. -
How to select Multiple items in the dvt:pivotfilterbar?
How to select Multiple items in the filters in the dvt:pivotfilterbar?
To select multiple media and other files, it's not possible. You can do so in messages as directed.
To select multiple files, connect to your PC and select them.
1. If any post helps you please click the below the post(s) that helped you.
2. Please resolve your thread by marking the post "Solution?" which solved it for you!
3. Install free BlackBerry Protect today for backups of contacts and data.
4. Guide to Unlocking your BlackBerry & Unlock Codes
Join our BBM Channels (Beta)
BlackBerry Support Forums Channel
PIN: C0001B7B4 Display/Scan Bar Code
Knowledge Base Updates
PIN: C0005A9AA Display/Scan Bar Code -
How to select multiple items in ListView?
Is it possible to select multiple items (rows) in ListView? I'm able
to select only one item at a time.
I'm running Forte 30F2 on Windows NT 4.0.
Thanks in advance,
Ramarao
Get Your Private, Free Email at http://www.hotmail.comRamarao,
I talked to Forte support about this recently and they had nothing but
bad news.
They said that you cannot select multiple rows in a listview, and that
this is a
feature that will be in the next release ( release 4 ).
I then asked if it was possible for me to highlight a row manually ( and
do the multiple
select myself ), and they said that also wasn't possible. This is due
to the fact that
there are no displaynode properties that effect display attributes (
like font or color ).
They suggested that I try changing the smallicon to show rows that have
been 'selected'.
In other words, when you ctrl-click on any particular row, you could put
an icon at the
beginning of a row that shows that this row has been clicked on.
I'm still working on this myself, so I will keep you posted.
Jeff Pickett
From: Ramarao P[SMTP:[email protected]]
Reply To: Ramarao P
Sent: Tuesday, March 24, 1998 6:22 PM
To: [email protected]
Subject: How to select multiple items in ListView?
Is it possible to select multiple items (rows) in ListView? I'm able
to select only one item at a time.
I'm running Forte 30F2 on Windows NT 4.0.
Thanks in advance,
Ramarao
Get Your Private, Free Email at http://www.hotmail.com -
How to select multiple items in JComboBox
Is it possible to select multiple items in a JComboBox
if yes, then how to do?
If no , then is there any other way to acheieve this ?Hi
ComboBoxModel extends ListModel and not ListSelectionModel, so i think JComboBox does not provide multiple selection. But u can try customizing ur combo box.. may be its possible.. not very sure
Shailesh -
How do i select multiple items on a page using firefox on a mac?
I am trying to to figure how to select multiple items (email addresses) using firefox on a mac. I use a web based manage my business. I am trying to send emails to multiple people.
I have tried clicking on the first email and hold the command key while selecting the others. The selection just jumps.
I tried holding the shift key and and it selects everything between the 1st and 2nd email address I want to use.
I also tried the control key which just brings up a menu.
Any help would be greatly appreciated.This may just be a limitation of the email site you are using. Is this a public site that I can test and try to reproduce the issue?
Maybe you are looking for
-
Every time I try to install firefox on my laptop i get a message saying that the installation was interrupted. I am using windows 7.
-
Hi , We have deployed our application on tomcat server built on struts framework. We have also set the domain name and are redirecting the domain name to Static Ip where our application is deployed with URL Masking option enabled. Everything is worki
-
i upgraded from 4S to Iphone 5 but i lost all my messages how can i get them back on the new device ?i did back up using the icloud ? having said that i have an i pad as well and when i backed up i got the contacts which are on the i pad on my new ip
-
Trouble with creating subdomains for .local address
I'm a web developer on Mac OS X 10.5.6 and I use my MacBook Pro as my primary development and testing machine. I have Apache 2 running and Entropy PHP 5.2.4. All of that works fine. In the past, I didn't use virtual hosts. Instead, I would divide my
-
Configurable product in CRM 7.0
Hi all, has anybody experience with configurable products and product model in CRM 7.0? or is there a detailed manual somewhere? the way to manage them seems quite different from the previous release in which the PME component was external. Thanks Or