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
scampercat
NA
189
0
C# 2010 textbox and submit buttons
Jun 17 2013 6:22 PM
In a C# 2010 desktop application, I would like to use the following code when
the user is selecting a file in a specified directory path:
OpenFileDialog dialog = new OpenFileDialog();
dialog.Filter = "txt files (*.txt)|*.txt|All files (*.*)|*.*";
dialog.InitialDirectory = "C:";
dialog.Title = "Select a text file";
if (dialog.ShowDialog() == DialogResult.OK)
{
strPKGID = dialog.FileName;
}
I would like to use the above code in the following situations:
1. When the text box containing the file location loses focus and
2. When a submit button on the form is clicked.
Would you show me code for losing focus on the textbox and clicking the submit button?
Reply
Answers (
3
)
how to pass two textboxs value to reportviewer in c# using
Asp.net mvc bulk upload into database