By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,626 Members | 2,202 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,626 IT Pros & Developers. It's quick & easy.

Form Minimize and Maximize

P: n/a
Hey Group,
When I minimize and then maximize a form (in windows application), I see a
significant drop in memory usuage in the task manager. I tried to do the
same thing programatically during the form load event, but I don't see any
significant drop in memory usage. Anybody know why?
Thanks,
Bhargavan
Nov 16 '05 #1
Share this Question
Share on Google+
7 Replies


P: n/a
Check out this blog post:

Reducing WinForm Memory Footprint with SetWorkingSet
http://west-wind.com/weblog/posts/240.aspx

--
Rob Windsor [MVP-VB]
G6 Consulting
Toronto, Canada
http://msmvps.com/windsor/

"Bhargavan" <bh********@yahoo.co.in> wrote in message
news:Oc**************@tk2msftngp13.phx.gbl...
Hey Group,
When I minimize and then maximize a form (in windows application), I see a
significant drop in memory usuage in the task manager. I tried to do the
same thing programatically during the form load event, but I don't see any
significant drop in memory usage. Anybody know why?
Thanks,
Bhargavan

Nov 16 '05 #2

P: n/a
Bhargavan,

Why are you trying to do this? Are you finding that it is consuming too
much memory and impacting other applications on the machine?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Bhargavan" <bh********@yahoo.co.in> wrote in message
news:Oc**************@tk2msftngp13.phx.gbl...
Hey Group,
When I minimize and then maximize a form (in windows application), I see a
significant drop in memory usuage in the task manager. I tried to do the
same thing programatically during the form load event, but I don't see any
significant drop in memory usage. Anybody know why?
Thanks,
Bhargavan

Nov 16 '05 #3

P: n/a
While I find the article informative, I think that the most important
line in it is:

In a way this is cheating the app but it certainly improves the impression
of memory usage of the application on the machine.

That doesn't mean it's actually doing anything. In the end, people
really need to learn what the number in task manager means, and why they
^shouldn't^ use it to gauge memory consumption or performance of a .NET
application.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Rob Windsor [MVP]" <ro*****************@gmail.com> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
Check out this blog post:

Reducing WinForm Memory Footprint with SetWorkingSet
http://west-wind.com/weblog/posts/240.aspx

--
Rob Windsor [MVP-VB]
G6 Consulting
Toronto, Canada
http://msmvps.com/windsor/

"Bhargavan" <bh********@yahoo.co.in> wrote in message
news:Oc**************@tk2msftngp13.phx.gbl...
Hey Group,
When I minimize and then maximize a form (in windows application), I see
a significant drop in memory usuage in the task manager. I tried to do
the same thing programatically during the form load event, but I don't
see any significant drop in memory usage. Anybody know why?
Thanks,
Bhargavan


Nov 16 '05 #4

P: n/a
Hey Nicholas,
Actually I am running my windows application over a terminal server. So at
any time there will be a number of instances of the same application on the
terminal server and thats the many reason for my memory concern. I am
already using SetProcessWorkingSetSize but I want to improve the performance
even further. Any suggestions?
Bhargavan

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> wrote in
message news:OH**************@tk2msftngp13.phx.gbl...
Bhargavan,

Why are you trying to do this? Are you finding that it is consuming
too much memory and impacting other applications on the machine?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Bhargavan" <bh********@yahoo.co.in> wrote in message
news:Oc**************@tk2msftngp13.phx.gbl...
Hey Group,
When I minimize and then maximize a form (in windows application), I see
a significant drop in memory usuage in the task manager. I tried to do
the same thing programatically during the form load event, but I don't
see any significant drop in memory usage. Anybody know why?
Thanks,
Bhargavan


Nov 16 '05 #5

P: n/a
Bhargavan,

Without knowing about your application, I can't really say. However, I
would focus on the code that you write, as opposed to the CLR when looking
for performance gains. This isn't to say that your coding is bad or
whatnot, but usually, gains can be made in your own code before looking at
the environment or the runtime.

--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Bhargavan" <bh********@yahoo.co.in> wrote in message
news:O5**************@tk2msftngp13.phx.gbl...
Hey Nicholas,
Actually I am running my windows application over a terminal server. So at
any time there will be a number of instances of the same application on
the terminal server and thats the many reason for my memory concern. I am
already using SetProcessWorkingSetSize but I want to improve the
performance even further. Any suggestions?
Bhargavan

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> wrote
in message news:OH**************@tk2msftngp13.phx.gbl...
Bhargavan,

Why are you trying to do this? Are you finding that it is consuming
too much memory and impacting other applications on the machine?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Bhargavan" <bh********@yahoo.co.in> wrote in message
news:Oc**************@tk2msftngp13.phx.gbl...
Hey Group,
When I minimize and then maximize a form (in windows application), I see
a significant drop in memory usuage in the task manager. I tried to do
the same thing programatically during the form load event, but I don't
see any significant drop in memory usage. Anybody know why?
Thanks,
Bhargavan



Nov 16 '05 #6

P: n/a
Hey Nicholas,
I don't think it is with my code. Even with just a blank form, you could see
the memory usuage drop drastically if you minimize and maximize it. You can
do this yourself. Just create a appliaction with a blank windows form in it.
Run it, see the memory usuage in task manager, then minimize and maximize
your application and check your memory usuage on the task manager again. You
will see a significant decrease in memory usuage. I am just trying to do the
same thing programatically (inside the form load event). But the memory drop
is not that significant and I donno why.
Bhargavan

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> wrote in
message news:%2****************@TK2MSFTNGP14.phx.gbl...
Bhargavan,

Without knowing about your application, I can't really say. However, I
would focus on the code that you write, as opposed to the CLR when looking
for performance gains. This isn't to say that your coding is bad or
whatnot, but usually, gains can be made in your own code before looking at
the environment or the runtime.

--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Bhargavan" <bh********@yahoo.co.in> wrote in message
news:O5**************@tk2msftngp13.phx.gbl...
Hey Nicholas,
Actually I am running my windows application over a terminal server. So
at any time there will be a number of instances of the same application
on the terminal server and thats the many reason for my memory concern. I
am already using SetProcessWorkingSetSize but I want to improve the
performance even further. Any suggestions?
Bhargavan

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> wrote
in message news:OH**************@tk2msftngp13.phx.gbl...
Bhargavan,

Why are you trying to do this? Are you finding that it is consuming
too much memory and impacting other applications on the machine?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Bhargavan" <bh********@yahoo.co.in> wrote in message
news:Oc**************@tk2msftngp13.phx.gbl...
Hey Group,
When I minimize and then maximize a form (in windows application), I
see a significant drop in memory usuage in the task manager. I tried to
do the same thing programatically during the form load event, but I
don't see any significant drop in memory usage. Anybody know why?
Thanks,
Bhargavan



Nov 16 '05 #7

P: n/a
What kind of machine are you developing in? I don't see that happening on
my laptop or my desktop for that matter.

--
in**@dowhileloop.com
http://dowhileloop.com website development
http://publicjoe.dowhileloop.com -- C# Tutorials

"Bhargavan" <bh********@yahoo.co.in> wrote in message
news:uF**************@TK2MSFTNGP10.phx.gbl...
Hey Nicholas,
I don't think it is with my code. Even with just a blank form, you could see the memory usuage drop drastically if you minimize and maximize it. You can do this yourself. Just create a appliaction with a blank windows form in it. Run it, see the memory usuage in task manager, then minimize and maximize
your application and check your memory usuage on the task manager again. You will see a significant decrease in memory usuage. I am just trying to do the same thing programatically (inside the form load event). But the memory drop is not that significant and I donno why.
Bhargavan

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> wrote in message news:%2****************@TK2MSFTNGP14.phx.gbl...
Bhargavan,

Without knowing about your application, I can't really say. However, I would focus on the code that you write, as opposed to the CLR when looking for performance gains. This isn't to say that your coding is bad or
whatnot, but usually, gains can be made in your own code before looking at the environment or the runtime.

--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Bhargavan" <bh********@yahoo.co.in> wrote in message
news:O5**************@tk2msftngp13.phx.gbl...
Hey Nicholas,
Actually I am running my windows application over a terminal server. So
at any time there will be a number of instances of the same application
on the terminal server and thats the many reason for my memory concern. I am already using SetProcessWorkingSetSize but I want to improve the
performance even further. Any suggestions?
Bhargavan

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.com> wrote in message news:OH**************@tk2msftngp13.phx.gbl...
Bhargavan,

Why are you trying to do this? Are you finding that it is consuming too much memory and impacting other applications on the machine?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"Bhargavan" <bh********@yahoo.co.in> wrote in message
news:Oc**************@tk2msftngp13.phx.gbl...
> Hey Group,
> When I minimize and then maximize a form (in windows application), I
> see a significant drop in memory usuage in the task manager. I tried to> do the same thing programatically during the form load event, but I
> don't see any significant drop in memory usage. Anybody know why?
> Thanks,
> Bhargavan
>



Nov 16 '05 #8

This discussion thread is closed

Replies have been disabled for this discussion.