473,395 Members | 1,440 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,395 software developers and data experts.

Bounded Listbox

I have 2 listbox binded to 2 datasource, one for the granted Roles & the
other to display all roles..
i set the DisplayMember to "RoleName" & valueMemeber to "RoleID".

I have 2 button to copy between 2 listbox.. how could i move the item from
one to another and update datasource???

listbox1.items.add(listbox2.SelectedItem); didn't work!!
need help plz
Nov 17 '05 #1
1 1259
Islamegy,

In order to do this, you would have to modify the underlying data source
(since they are bound). When you want to copy from one to the other, you
have to remove the row in the source, and add it to the new data source (a
data table, I assume).

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Islamegy" <islamegy#@#yahoo#.#com> wrote in message
news:uY**************@tk2msftngp13.phx.gbl...
I have 2 listbox binded to 2 datasource, one for the granted Roles & the
other to display all roles..
i set the DisplayMember to "RoleName" & valueMemeber to "RoleID".

I have 2 button to copy between 2 listbox.. how could i move the item from
one to another and update datasource???

listbox1.items.add(listbox2.SelectedItem); didn't work!!
need help plz

Nov 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

17
by: amber | last post by:
Hello. Can someone tell me what I may be doing wrong here? I'm using the code (lboxRP is a listbox): Dim newRPindex As Integer newRPindex = Me.lboxRP.FindString(RP)...
1
by: Krzysztof Karnicki | last post by:
I have such a problem… I have create my custom DataGridColumn inheriting from System.Windows.Forms.DataGridColumnStyle on using it on DataGrid, to show rows painted by me self. Because dates ...
2
by: Islamegy | last post by:
Some of my win forms was delay couple of seconds when loaded for first time.. i thought there is a problem with the sqlconnection or database but the adapter make no problem when bind to grid?! ...
6
by: Chris Leuty | last post by:
I am populating a multiselect Listbox from a dataset, with the content of the listbox filled by one table, and the selections determined from another table. So far, I have been keeping the dataset...
1
by: basulasz | last post by:
May be it is a bit easy question but i don't know the way to display data in bounded colums. I get data from DB with a datareader, and I want to display them on bounded colums. I dont want to...
3
by: Ali Chambers | last post by:
Hi, I have created a listbox called "dtlist1" on my VB.NET form. I call a procedure as follows: Private Sub openfile(flname As String) dtlist1.Items.Clear() etc..
7
by: GabyFont | last post by:
Hi, I'm new to Access so excuse if my question is too simple. I'm creating an app to manage spare objects in my company. So a user select from list boxes the criteria they want and hit a button...
5
by: karsagarwal | last post by:
I have a bounded form and after I click the button to update/save. THe fields are still there. Is there a way to clear off the fields in the bounded form. Thanks, SA Here's the code that I...
5
by: agarwasa2008 | last post by:
Hi, I have a linked table called tbltest and some bounded forms (which add, update, delete records) that were created using that linked table. For some necessary reasons I had to create another...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.