471,603 Members | 1,821 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,603 software developers and data experts.

minimize, maximize buttons on the top,right hand corner of my form

jj

I have a single threaded application in c# that scans through a file system.
While doing this if I try to minimize, maximize buttons on the top,right
hand corner of my form do not do as they are supposed to do. To maximize the
window I have to go to "task manager" and double click the application.

How do I control those maximize, minimize buttons on the top right section
of my form?
A learner here
Thanks
Feb 6 '06 #1
2 2693
>I have a single threaded application in c# that scans through a file system.

Why don't you do the work on a background thread to keep your UI
responsive?
Mattias

--
Mattias Sjögren [C# MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.
Feb 6 '06 #2
Hi jj,
the control box buttons should work without any intervention from you. I
suspect that they work before you start your scan (not mentioned) and after.
This probably means that you are doing a lot of intensive processing in the
main UI thread which is in charge of handling UI requess. The main UI thread
does not get chance to process the UI messages while your intensive
processing is going on so the UI becomes unresponsive. The solution is to
move your processing in to a new thread, not the main UI thread, this way the
main UI thread is still free to handle requests during the intensive
processing. For a great tutorial on this check out:

http://www.yoda.arachsys.com/csharp/...winforms.shtml

This should answer all of your questions.

Hope that helps
Mark Dawson
http:/www.markdawson.org


"jj" wrote:

I have a single threaded application in c# that scans through a file system.
While doing this if I try to minimize, maximize buttons on the top,right
hand corner of my form do not do as they are supposed to do. To maximize the
window I have to go to "task manager" and double click the application.

How do I control those maximize, minimize buttons on the top right section
of my form?
A learner here
Thanks

Feb 6 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

11 posts views Thread by M O J O | last post: by
4 posts views Thread by EmilH | last post: by
reply views Thread by leo001 | last post: by
reply views Thread by MichaelMortimer | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.