how to find memory size occupied for my application in vb,net ?

I am developing application in vb.net. my application has 20 forms.  this application is now running.  while this application is running , I want to find that  how many  size has ocuupied in memory  for my application ?
how to find it ?
tamilsoftAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Paul MacDonaldDirector, Information SystemsCommented:
If you start the Task Manager (right-click on the task bar) the processes tab will show you your .exe and it's memory usage.
0
Miguel OzSoftware EngineerCommented:
Task manager is not reliable, it does not show the real memory usage. You are better off using Process Explorer:
http://technet.microsoft.com/en-us/sysinternals/bb896653

If you are interested in keep track of this value in production as well, you need to log the memory usage(or show it in a label in your app updated by a timer) using:
http://msdn.microsoft.com/en-us/library/system.diagnostics.process.privatememorysize64.aspx#Y648

Sample code
Dim myProcess As Process = Process.GetCurrentProcess()
Console.WriteLine("  PagedMemorySize64: {0}", myProcess.PagedMemorySize64)


0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Bob LearnedCommented:
I would think that Environment.WorkingSet is what you are looking for.

Environment.WorkingSet Property
http://msdn.microsoft.com/en-us/library/system.environment.workingset.aspx
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic.NET

From novice to tech pro — start learning today.