#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2012
    Posts
    7
    Rep Power
    0

    Question Static vs dynamic allocation


    My application will have several small input forms which will be rarely used and contain a limited number of objects. My question to you is: is it worth creating these forms statically (giving them their own unit) and have them hidden in the background even though they'll rarely be needed, or should I create them dynamically on the spot when they're being called and free them after use?
    What's the most efficient way to approach this?

    Thanks for the input.
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2008
    Posts
    356
    Rep Power
    7
    I almost never opt to have the application autocreate all my secondary forms.

    One thing to take into consideration, if you want your form to remember its previous state (last time your user used the form), then autocreating the form and hiding it would be better (don't confuse this with having the form remember its state the last time the application was run).
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Regular (2000 - 2499 posts)

    Join Date
    Jan 2006
    Location
    Carlsbad, CA
    Posts
    2,057
    Rep Power
    383
    I agree with majlumbo.
    Personally I store and retrieve any information about forms that I want the application
    to "remember" to an XML configuration file.

    Clive

IMN logo majestic logo threadwatch logo seochat tools logo