CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2

Thread: Applets

  1. #1
    Join Date
    Mar 1999
    Posts
    4

    Applets

    I am frequently getting Out of memory exception in my applet when it is run for a long time. How to remove this exception ?


  2. #2
    Join Date
    Apr 1999
    Location
    Bangalore,India
    Posts
    43

    Re: Applets

    If u r using the browser, u can use the Java Plugin.(Just a suggestion).
    Install the Java-Plugin in your machine. After that go to your Java-Plugin Control Panel, which u can see under Start->Programs. U can find a text box for setting the Java Runtime Parameters.
    There set the value for the heapsize of the browser JVM as -Xms2M -Xmx6M. Just try this. I haven't tried this out. If it works reply.

    Also while creating objects,take care that u are not creating them unnecessariy. Then reduce the scope of the object and also make objects eqaul to null if u won't need them. This allows GC to do garbage collection and some memory will be available for your memory allocation pool(ie. heap). As you said your program runs for a long time, then this above thing will solve your problem more.


    Hope this might solve yours.

    regards,
    arun...


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured