473,471 Members | 2,140 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

C# mover

Hi,

Does somebody have an example C# code of how to move items between two
lisbboxes? Or maybe a ready to go component. I found an ASP example, but is
there something for Windows forms project?

Thanks,
Andy

Jun 8 '07 #1
6 1905
Andy,

Do you need something that is drag and drop, or you just want to click a
button and move items selected in one to another?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Andy Summers" <an*********@polyoptimum.comwrote in message
news:eh**************@TK2MSFTNGP03.phx.gbl...
Hi,

Does somebody have an example C# code of how to move items between two
lisbboxes? Or maybe a ready to go component. I found an ASP example, but
is there something for Windows forms project?

Thanks,
Andy

Jun 8 '07 #2
I believe the fastest way will be to move data source. If you have
datasource. If not, probably it will be easier to create one and then you
can switch listboxes in couple of = operators.

HTH
Alex

"Andy Summers" <an*********@polyoptimum.comwrote in message
news:eh**************@TK2MSFTNGP03.phx.gbl...
Hi,

Does somebody have an example C# code of how to move items between two
lisbboxes? Or maybe a ready to go component. I found an ASP example, but
is there something for Windows forms project?

Thanks,
Andy

Jun 8 '07 #3
The one with the buttons will do.

Thanks,
Andy

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.comwrote in
message news:e3**************@TK2MSFTNGP03.phx.gbl...
Andy,

Do you need something that is drag and drop, or you just want to click
a button and move items selected in one to another?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Andy Summers" <an*********@polyoptimum.comwrote in message
news:eh**************@TK2MSFTNGP03.phx.gbl...
>Hi,

Does somebody have an example C# code of how to move items between two
lisbboxes? Or maybe a ready to go component. I found an ASP example, but
is there something for Windows forms project?

Thanks,
Andy

Jun 8 '07 #4
Andy,

I'm assuming you are manually populating the Items collection? If so,
you should be able to remove the items from the collection using the Remove
method, and Add them to the other collection using the Add method.

If these are data-bound lists, then you will have to work with the
underlying data source, depending on what it is, and if it supports updating
the list itself.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Andy Summers" <an*********@polyoptimum.comwrote in message
news:eg**************@TK2MSFTNGP03.phx.gbl...
The one with the buttons will do.

Thanks,
Andy

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.comwrote
in message news:e3**************@TK2MSFTNGP03.phx.gbl...
>Andy,

Do you need something that is drag and drop, or you just want to click
a button and move items selected in one to another?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Andy Summers" <an*********@polyoptimum.comwrote in message
news:eh**************@TK2MSFTNGP03.phx.gbl...
>>Hi,

Does somebody have an example C# code of how to move items between two
lisbboxes? Or maybe a ready to go component. I found an ASP example, but
is there something for Windows forms project?

Thanks,
Andy


Jun 8 '07 #5

"AlexS" <sa***********@SPAMrogers.comPLEASEwrote in message
news:eB**************@TK2MSFTNGP02.phx.gbl...
>I believe the fastest way will be to move data source. If you have
datasource. If not, probably it will be easier to create one and then you
can switch listboxes in couple of = operators.
I think the requirement is to move individual items, not swap the whole
lists.
>
HTH
Alex

"Andy Summers" <an*********@polyoptimum.comwrote in message
news:eh**************@TK2MSFTNGP03.phx.gbl...
>Hi,

Does somebody have an example C# code of how to move items between two
lisbboxes? Or maybe a ready to go component. I found an ASP example, but
is there something for Windows forms project?

Thanks,
Andy


Jun 8 '07 #6
there some good examples

in the help

we go it to work easy as

steve
Andy Summers <an*********@polyoptimum.comwrote in message
news:eh**************@TK2MSFTNGP03.phx.gbl...
Hi,

Does somebody have an example C# code of how to move items between two
lisbboxes? Or maybe a ready to go component. I found an ASP example, but
is
there something for Windows forms project?

Thanks,
Andy

Jun 9 '07 #7

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

Similar topics

1
by: Joe Abou Jaoude | last post by:
I was asked to do the folowing visual effect, and I was wondering if someone knows how to. To view the visual effect , go to this link: http://v4.windowsupdate.microsoft.com/en/default.asp...
7
by: ivanhoe | last post by:
I've got constructor like this(just short example): function Item() { this.elem = document.body.appendChild(document.createElement('div')); this.elem.onmouseover = this.mOver; ... return this;...
5
by: francisco lopez | last post by:
hi, well I think I will forget the earthquake-effect, because it doesn´t run in a frame with IE, so I need now another funny prank, but not the format C: fake, I was thinking for example that a...
3
by: effendi | last post by:
Hi Can any tell me what is the javascript equivalent of CSS border? I would like to change the border of my cell when it is set on focus. I have tried onFocus="style.border='3px'" but it is not...
6
by: Brendan.Collins | last post by:
Hi I have a javascript problem that has been annoying me for two days now and thought that a javascript expert might have the magic solution. I am populating a table dynamically from the...
3
by: Dooza | last post by:
Hi there, I was wondering if anyone had come across some javascript that would allow me to have a chart of say 20 music tracks, and be able to move each track up and down the chart using up/down...
12
by: zacks | last post by:
Suddenly, in a VB2005 project I am working on, several variables show up in the list of warnings are being unused local variables. But they all are. Several of them are the ex variable used in a...
12
by: Jim Langston | last post by:
I want to change a class's methods at run time. I'm making a game and want NPC objects to have different methods depending on a game designer. That is, they may decide that this mob should be...
1
oranoos3000
by: oranoos3000 | last post by:
hi would you please help me i have a online shopping center that i show pictures of the my product in home page. in the InterExplorer pictures is shown correctly but in Firefox browser is shown...
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
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...
1
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
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.