Welcome to Dream.In.Code
Getting C# Help is Easy!

Join 136,110 C# Programmers for FREE! Get instant access to thousands of C# experts, tutorials, code snippets, and more! There are 1,718 people online right now. Registration is fast and FREE... Join Now!




listbox and database

 
Reply to this topicStart new topic

listbox and database, how to use listbox connect to data base

chenli0513
25 Nov, 2007 - 05:12 PM
Post #1

New D.I.C Head
*

Joined: 25 Nov, 2007
Posts: 2


My Contributions
CODE

oleDbReader reader=oleDbCommand1.ExcuteReader()
while(reader.Read())&&(i<10)&&(  one conditon)  )//that's condition is use select the match anwer from database
{
listBox1.item.Add(reader.GetInt32(0).ToString());
.
..
..
i++
}

thank you !

This post has been edited by chenli0513: 25 Nov, 2007 - 05:13 PM
User is offlineProfile CardPM
+Quote Post

PsychoCoder
RE: Listbox And Database
29 Nov, 2007 - 10:35 PM
Post #2

using DIC.Core;
Group Icon

Joined: 26 Jul, 2007
Posts: 8,983



Thanked: 125 times
Dream Kudos: 8600
Expert In: VB, VB.Net, C#, SQL, ASP, ASP.Net, Web Development, HTML, CSS, Win32 API, Javascript, mySQL, J#, Boo.Net

My Contributions
How about providing us with an explanation of exactly what you're trying to do, not just bits & pieces of code and expecting us to interpret it for you smile.gif
User is online!Profile CardPM
+Quote Post

chenli0513
RE: Listbox And Database
30 Nov, 2007 - 08:18 AM
Post #3

New D.I.C Head
*

Joined: 25 Nov, 2007
Posts: 2


My Contributions
QUOTE(PsychoCoder @ 29 Nov, 2007 - 11:35 PM) *

How about providing us with an explanation of exactly what you're trying to do, not just bits & pieces of code and expecting us to interpret it for you smile.gif


User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic
Time is now: 12/1/08 09:35PM

Live C# Help!

C# Tutorials

Reference Sheets

C# Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month