Solved

remove item from Bind listBox control with sql data in vb.net windows Application

Posted on 2013-01-30
3
895 Views
Last Modified: 2013-02-07
How to remove item from Bind listBox control with sql data in vb.net windows Application?
0
Comment
Question by:mohgt
  • 2
3 Comments
 
LVL 42

Assisted Solution

by:sedgwick
sedgwick earned 167 total points
ID: 38834778
what item?
can u post some code?

try this:

dt.Rows.Remove((listBox.SelectedItem as DataRowView).Row)

Open in new window

0
 
LVL 35

Assisted Solution

by:YZlat
YZlat earned 333 total points
ID: 38836497
you could filter your SqlDataSource and the refresh listbox
0
 
LVL 35

Accepted Solution

by:
YZlat earned 333 total points
ID: 38836510
if you are not using SqlDataSource to bind your listbox, then something like

ListBox1.Items.Remove(ListBox1.SelectedItem)

will suffice
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Introduction SQL Server Integration Services can read XML files, that’s known by every BI developer.  (If you didn’t, don’t worry, I’m aiming this article at newcomers as well.) But how far can you go?  When does the XML Source component become …
Slowly Changing Dimension Transformation component in data task flow is very useful for us to manage and control how data changes in SSIS.
Using examples as well as descriptions, and references to Books Online, show the different Recovery Models available in SQL Server and explain, as well as show how full, differential and transaction log backups are performed
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now