473,320 Members | 1,839 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

how to do mulitline selection in ListBox control in C#.Net

hi everyone,

I have a query. I want to know how to select multiple values from a list box control in C#.Net.. Please help me out..

Thanks in advance..

With regrads,
Manivel. K
Feb 25 '08 #1
3 1054
kenobewan
4,871 Expert 4TB
Set ListBox1.SelectionMode = ListSelectionMode.Multiple and ListBox1.Items[i].Selected = true. The rest you should be able to do yourself. HTH.
Feb 25 '08 #2
Hi,

Thanks for your reply.. i checked out that property.. But it selects the whole list elements. I want to select the required items only.. Please help me out..

Thank in advance..
Feb 26 '08 #3
kenobewan
4,871 Expert 4TB
Some people say that its 'x' who is important, but miss that 'i' can have more utility than 'u'...
Feb 28 '08 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: (Pete Cresswell) | last post by:
Seems like I've been here before, but can't find anyting in Google. I've got two list boxes on a form. Seems to me like the inactive ListBox's selection rectangle should be something like...
2
by: DK | last post by:
Hello everybody ! I need little help from Your side. I have form called Form2, and ListBox called List 20. Property of List 20 allow multiple selection. Also I have query called Distribution as...
2
by: Matt Sawyer | last post by:
Hi, I'm attempting to do a drag and drop operation from one listbox to another. I have my listboxes setup with SelectionMode = MultiExtended so that I can use the shift key, cntrl key, etc. to...
5
by: Lie | last post by:
Hi all, I have problem in getting selectedindex of multiple listbox selection in a datagrid. I have a listbox with multiple selection mode inside datagrid. In Edit mode, I need to get back all...
1
by: Paul | last post by:
I have a dropdownlist and populate it from a stored procedure with strings like names. When the user has it in focus if the hit a letter the selection will go to the first string starting with...
5
by: Dave H | last post by:
I have an asp:listbox, allowing multiple selections, is there a quick check to see if there's more than one selected, or do I need to go through the whole list? Thanks, Dave
1
by: barbara_dave | last post by:
Hi, all, I know Listbox control has multiple and single mode for item selection. I need to use multiple selection mode, but I like to select items with shift or ctrl key and mouse. The reason...
4
by: kimiraikkonen | last post by:
Hi, I have a odd but a known question about listbox. I know listbox control can provide multi-select, multi-extendend selections. But i wonder if this selection type belongs to them or it has...
0
by: Lloyd Sheen | last post by:
1st let me apologize for creating new thread but using Windows Mail and old one is gone all read. What I was asking if there was a "generic" method of capturing control events and doing the...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.