Results 1 to 3 of 3

Thread: Imported unused classes

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Apr 2010
    Posts
    478

    Imported unused classes

    In order to solve asp.net app memory leaking problem (as IIS admin told me), I double checked my asp.net app code.
    I found out that some classes are imported but never used.
    Does it cause memory leaking?

  2. #2
    Fanatic Member
    Join Date
    Jan 2006
    Posts
    710

    Re: Imported unused classes

    Do you mean the 'Imports' statements?

    These would never cause memory leaks - they are just to allow you to refer to types without full qualification and are resolved before compiling.
    David Anton
    Convert between VB, C#, C++, & Java
    www.tangiblesoftwaresolutions.com

  3. #3
    PowerPoster gep13's Avatar
    Join Date
    Nov 2004
    Location
    The Granite City
    Posts
    21,963

    Re: Imported unused classes

    Hello,

    To be clear, you don't Import classes, you Import a reference to an assembly which contains classes.

    The answer to your question is no, an Import of an assembly will not by itself cause memory leaks. There are a number of profiler which you can run on your code though to see if you have any issues.

    Gary

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