TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Song Lee
NA
47
38.4k
Displaying user input into listbox
Nov 23 2014 8:53 PM
Hello,
I am making a winform application that retrieves data from user with text box, and display on listBox.
Below is the ones I tried, but no error, and it's not working.
Help please! :)
private void
Button_Click(
object
sender,
EventArgs
e)
{
current.name = nameTextBox.Text.Trim();
current. description = descriptionTextBox.Text.Trim();
listBox.BeginUpdate();
listBox.Items.Clear();
string
row =
String
.Format (
"{0} {1}"
, current.name, current description);
//listBox.Items.Add("{0} {1}", current.name, current description); //Another method I tried, but didn't work.
listBox.EndUpdate();
}
Reply
Answers (
2
)
Console.Writeline doesn't show up
C# - Submitting Windows form to SQLite database