Click here to Skip to main content
15,905,782 members
Home / Discussions / Windows Forms
   

Windows Forms

 
Question[Deployment] Immediately run application after setup Pin
Accius30-Oct-08 7:37
Accius30-Oct-08 7:37 
QuestionRe: [Deployment] Immediately run application after setup Pin
led mike31-Oct-08 4:39
led mike31-Oct-08 4:39 
QuestionPrint a form Pin
shir129-Oct-08 22:22
shir129-Oct-08 22:22 
AnswerRe: Print a form Pin
Giorgi Dalakishvili29-Oct-08 22:40
mentorGiorgi Dalakishvili29-Oct-08 22:40 
Questionwin app to silverlight? Pin
codeflat29-Oct-08 2:12
codeflat29-Oct-08 2:12 
AnswerRe: win app to silverlight? Pin
Simon P Stevens29-Oct-08 5:57
Simon P Stevens29-Oct-08 5:57 
QuestionPlug-in for Outlook using C# Pin
A.Asif28-Oct-08 18:47
A.Asif28-Oct-08 18:47 
RantRe: Plug-in for Outlook using C# Pin
Paul Conrad3-Nov-08 5:04
professionalPaul Conrad3-Nov-08 5:04 
QuestionDataGrid in CF 2.0 Pin
Member 62799727-Oct-08 17:10
Member 62799727-Oct-08 17:10 
QuestionTrackBar appearance inconsistency Pin
John Whitmire27-Oct-08 11:12
professionalJohn Whitmire27-Oct-08 11:12 
GeneralRe: TrackBar appearance inconsistency Pin
Luc Pattyn27-Oct-08 11:31
sitebuilderLuc Pattyn27-Oct-08 11:31 
AnswerRe: TrackBar appearance inconsistency Pin
John Whitmire28-Oct-08 5:23
professionalJohn Whitmire28-Oct-08 5:23 
QuestionShowing and manipulating a window form Pin
dj_jeff27-Oct-08 4:13
dj_jeff27-Oct-08 4:13 
AnswerRe: Showing and manipulating a window form Pin
JoeSharp27-Oct-08 4:38
JoeSharp27-Oct-08 4:38 
GeneralRe: Showing and manipulating a window form Pin
dj_jeff27-Oct-08 20:14
dj_jeff27-Oct-08 20:14 
GeneralRe: Showing and manipulating a window form Pin
Luc Pattyn27-Oct-08 6:04
sitebuilderLuc Pattyn27-Oct-08 6:04 
Hi,

if all the code you've shown is running on the GUI thread (say inside a
button_click handler) then none of it will have a visible effect, since
the GUI actions will get queued until your code reaches its end: it is only
when the GUI thread is done dealing with the button click that it can start executing the queued stuff in a hurry.

Do you really want to show a form and (almost immediately) close it again??
Normally a form gets closed by an explicit user action, such as clicking
an OK button or the close box.

Remedy: reorganise your code, at least separate the Form.Close from everything
else (use another event, such as a button click, a timer tick, whatever).

BTW: DO NOT include delays in handlers, don't try Thread.Sleep() inside a
button click handler, it does not make any sense whatsoever.

Mind you there is one dangerous hack that may or may not be useful here:
include some Application.DoEvents() calls; they are bound to cause weird
effects if used inappropriately though.

Smile | :)

Luc Pattyn [Forum Guidelines] [My Articles]

Fixturized forever. Confused | :confused:


GeneralRe: Showing and manipulating a window form Pin
dj_jeff27-Oct-08 20:17
dj_jeff27-Oct-08 20:17 
AnswerRe: Showing and manipulating a window form Pin
dybs1-Nov-08 17:13
dybs1-Nov-08 17:13 
GeneralRe: Showing and manipulating a window form Pin
dj_jeff4-Nov-08 6:46
dj_jeff4-Nov-08 6:46 
QuestionPlz , I want help !! :( Pin
ahmed.mli27-Oct-08 1:02
ahmed.mli27-Oct-08 1:02 
Questiondatagridview sort Pin
CICCIOLO6923-Oct-08 13:19
CICCIOLO6923-Oct-08 13:19 
Questionprint a bitmap backround Pin
PaulaM22-Oct-08 22:41
PaulaM22-Oct-08 22:41 
AnswerRe: print a bitmap backround Pin
Thomas Stockwell24-Oct-08 4:20
professionalThomas Stockwell24-Oct-08 4:20 
QuestionTask list Pin
boiDev22-Oct-08 22:24
boiDev22-Oct-08 22:24 
AnswerRe: Task list Pin
Tom Deketelaere22-Oct-08 23:19
professionalTom Deketelaere22-Oct-08 23:19 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.