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
Chavdar
NA
3
0
How to show form and execute code without user input?
Mar 14 2011 5:48 AM
Hello,
this is probably an easy question, but I'm new to Windows Forms and can't seem to find anything on the Internet, so here it is:
I have a form, which connects to a WCF service and sends a file to the server. While doing that, the form should display some images and status messages. The only way I could get this to work is to have the user click a button for the whole thing to start. If I try to execute the code after InitializeComponent() or in Main(), it waits for it to finish execution, and only then shows the form with all text and images already in place. I tried using Button.PerformClick() on said button, but it didn't seem to work.
Is there a way to make it work without user input? The form will be started from another program with all command-line parameters it needs, so I don't really want another button click.
Thanks a lot,
Chavdar
Reply
Answers (
3
)
Windows application has stopped working. Error message
Is this possible to open up a link in window forms application