473,813 Members | 2,514 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Memory Usage

Hi all,

I wrote a tiny little Windows Forms application that periodically checks
a database for certain conditions and then pops up a message box asking if
you want to do something about those conditions. It runs in the system
tray. I find that when I start this program, it automatically eats up 11 MB
of memory on my machine. When the prompt appears, that climbs to 17 MB.

If a user answers yes to the prompt, it will open another window that
has a web browser control built onto it. (This is just the old web browser
control that I would have used if I had built the thing using VB6) So an
Interop assembly exists as well. When this form loads, memory usage jumps
to 36 MB. This is craziness since the application is so small and simple.

Is it normal for a VB application built using .NET to take this much
memory? I even tried tunning other VB.NET apps that are shipped as samples,
and their initial memory usage seems to be a bit high as well. My
supervisor saw this and wants an explanation. Best I could offer is that
this extra memory is for the Just-In-Time compilation and the managed
environment we get with .NET. Is this true?

Stephajn
Nov 20 '05 #1
3 1595
Hi there! See my post on that topic. It was posted on 13-01-2004 at 15.21.
I didn't copy and paste because there were several answers.
Hope it helps!

Andre Nogueira

"Stephajn Craig" <s.*****@NOSPAM .funsunvacation s.com> wrote in message
news:Ow******** ******@TK2MSFTN GP10.phx.gbl...
Hi all,

I wrote a tiny little Windows Forms application that periodically
checks
a database for certain conditions and then pops up a message box asking if
you want to do something about those conditions. It runs in the system
tray. I find that when I start this program, it automatically eats up 11
MB
of memory on my machine. When the prompt appears, that climbs to 17 MB.

If a user answers yes to the prompt, it will open another window that
has a web browser control built onto it. (This is just the old web
browser
control that I would have used if I had built the thing using VB6) So an
Interop assembly exists as well. When this form loads, memory usage jumps
to 36 MB. This is craziness since the application is so small and simple.

Is it normal for a VB application built using .NET to take this much
memory? I even tried tunning other VB.NET apps that are shipped as
samples,
and their initial memory usage seems to be a bit high as well. My
supervisor saw this and wants an explanation. Best I could offer is that
this extra memory is for the Just-In-Time compilation and the managed
environment we get with .NET. Is this true?

Stephajn

Nov 20 '05 #2
Well that answers that question about the IE Control, but what about before
that's loaded? My application, without doing anything but running a Windows
Forms Timer control is eating up 17 MB of RAM. that seems a bit much. (Or
does it?)

Stephajn
"Andre Nogueira" <an**@netcabo.p t.NOSPAM> wrote in message
news:O2******** ******@tk2msftn gp13.phx.gbl...
Hi there! See my post on that topic. It was posted on 13-01-2004 at 15.21.
I didn't copy and paste because there were several answers.
Hope it helps!

Andre Nogueira

"Stephajn Craig" <s.*****@NOSPAM .funsunvacation s.com> wrote in message
news:Ow******** ******@TK2MSFTN GP10.phx.gbl...
Hi all,

I wrote a tiny little Windows Forms application that periodically
checks
a database for certain conditions and then pops up a message box asking if you want to do something about those conditions. It runs in the system
tray. I find that when I start this program, it automatically eats up 11 MB
of memory on my machine. When the prompt appears, that climbs to 17 MB.

If a user answers yes to the prompt, it will open another window that
has a web browser control built onto it. (This is just the old web
browser
control that I would have used if I had built the thing using VB6) So an Interop assembly exists as well. When this form loads, memory usage jumps to 36 MB. This is craziness since the application is so small and simple.
Is it normal for a VB application built using .NET to take this much
memory? I even tried tunning other VB.NET apps that are shipped as
samples,
and their initial memory usage seems to be a bit high as well. My
supervisor saw this and wants an explanation. Best I could offer is that this extra memory is for the Just-In-Time compilation and the managed
environment we get with .NET. Is this true?

Stephajn


Nov 20 '05 #3
* "Stephajn Craig" <s.*****@NOSPAM .funsunvacation s.com> scripsit:
Well that answers that question about the IE Control, but what about before
that's loaded? My application, without doing anything but running a Windows
Forms Timer control is eating up 17 MB of RAM. that seems a bit much. (Or
does it?)


I think that's still normal if the memory usage is not increasing from
time to time (maybe memory leak).

--
Herfried K. Wagner [MVP]
<http://www.mvps.org/dotnet>
Nov 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
3678
by: rbt | last post by:
Would a Python process consume more memory on a PC with lots of memory? For example, say I have the same Python script running on two WinXP computers that both have Python 2.4.0. One computer has 256 MB of Ram while the other has 2 GB of Ram. On the machine with less Ram, the process takes about 1 MB of Ram. On the machine with more Ram, it uses 9 MB of Ram. Is this normal and expected behavior?
5
6094
by: Justice | last post by:
Currently I'm doing some experimenting with the XMLHTTP object in Javascript. Now, the XMLHttp object is asynchronous (at least in this case), and the following code causes a significant memory loss even though I seem to be allocaitng everything; help would be *vastly* appreciated. What am I doing wrong here? I thought I was doing everything correctly (setting things to null, for example) but none of the memory seems to get replaced. ...
2
460
by: tomvr | last post by:
Hello I have noticed some 'weird' memory usage in a vb.net windows app The situation is as follows I have an app (heavy on images) with 2 forms (actually there are more forms and on starting the app I load some things into memory for global use of the app but I'll use only 2 starting forms to explain the situation) situation 1 start app with form 1 (72mb memory usage), show form 2 and hide form 1 (89 mb memory usage
6
3280
by: Tom | last post by:
We have a VERY simple .NET C# Form Application, that has about a 23MB Memory Footprint. It starts a window runs a process and does a regular expression. I have done a GC.Collect to make sure that, no memory is lying around. GC reports only 84k of allocations. Starting 5-10 of this apps is going to start taking a considerable amount of memory. Is there a way to reduce this? Tom
2
422
by: Jarvis | last post by:
I've made a testing program to test the memory usage of some Data Forms. I create a MDI parent form with one single MDI child form, which is a Data Form generated by .NET Data Form Wizard. To test the stuff, I keep to open that child data form for about 10 times. the memory usage shown in GC and task manager both increase. Then I close all those forms. and perform GC collect. The memory usage shown in GC falls, however, the memory...
3
4155
by: Ian Taite | last post by:
Hello, I'm exploring why one of my C# .NET apps has "high" memory usage, and whether I can reduce the memory usage. I have an app that wakes up and processes text files into a database periodically. What happens, is that the app reads the contents of a text file line by line into an ArrayList. Each element of the ArrayList is a string representing a record from the file. The ArrayList is then processed, and the arraylist goes out of...
20
4252
by: Philip Carnstam | last post by:
How come .Net applications use so much memory? Every application I compile uses at least 10 MB of memory, even the ones consisting of only a form and nothing else. If I minimize them though the memory usage drops to a couple hundred KB. Why? Is there anything I should to to prevent this? I have compiled in release and deactivated all forms of debugging, I think! Thanks, Philip
13
2865
by: Ilias Lazaridis | last post by:
How to detect memory leaks of python programms, which run in an environment like this: * Suse Linux 9.3 * Apache * mod_python The problem occoured after some updates on the infrastructure. It's most possibly caused by trac and it's dependencies, but several components of the OS where updated, too.
1
1733
by: yzghan | last post by:
Hi all, I feel that my python script is leaking memory. And this is a test I have: log.write(" " + "test() ... memory usage: " + " ".join(repr(i/(1024*1024)) for i in getMemInfo()) + "\n") m = {} i = 1000*1000 while i 0:
1
2051
by: Jean-Paul Calderone | last post by:
On Tue, 22 Apr 2008 14:54:37 -0700 (PDT), yzghan@gmail.com wrote: The test doesn't demonstrate any leaks. It does demonstrate that memory usage can remain at or near peak memory usage even after the objects for which that memory was allocated are no longer live in the process. This is only a leak if peak memory goes up again each time you create any new objects. Try repeated allocations of a large dictionary and observe how memory...
0
9734
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9607
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10407
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9224
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7684
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6897
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5706
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3885
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3030
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.