Is there a proper way to manage application size?-VBForums
Results 1 to 7 of 7

Thread: Is there a proper way to manage application size?

  1. #1

    Thread Starter
    Fanatic Member jdc20181's Avatar
    Join Date
    Oct 2015
    Location
    Indiana
    Posts
    1,019

    Is there a proper way to manage application size?

    I am getting to the part in my knowledge of programming I need to know more about some of the broad subjects.

    One of them being what is the proper way to manage the amount of space an application takes to install?

    I have two versions of my browser, one is near 200mb and one which has less, and only the needed components to browse, is only ~78mb

    Why is it that even though there is very little difference as far as this goes that it is ~120mb lighter? Does each window component really consume that much space when compiled?

    I know this isn't an easy question, or maybe I am wrong and it is, but I think that it is a broad rough question that needs some answers or input if not neccessarily an answer.

    Thanks Greatly!

    P.s. I am speaking specifically about .NET Windows Forms, and only posted in vb.net as that is the only .net language I use, and involves my project(s)
    Disclaimer: When code is given for example - it is merely a example. See my First CodeBank Submission Upgrading to the newest IE when using the Webbrowser control See my Second CodeBank SubmissionVB.NET - Recording History or changes using WebbrowserControl RichTextBox Textbox
    See my Third codebank submission VB.NET - Detecting Secure/Insecure Websites (ssl) w/ Webbrowser control See CodeBank Submission 4 A Simple Large View Calendar Control See my browser project BeffsBrowser Try my SpeedTest Project

    Unless said otherwise (e.g. From one of my projects thus, those are mostly licensed under MIT) - All Code snippets advice or otherwise that I post on this site, are expressly licensed under Creative Commons Attribution 4.0 International Please respect my copyrights.

  2. #2
    .NUT jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    97,077

    Re: Is there a proper way to manage application size?

    There is a .NET Architecture & Design forum that is more appropriate for questions like this. I've asked the mods to move this thread there.

    There's no way to comment on your specific case without knowing more about it but things like included libraries and image resources are going to make your installation package bigger.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  3. #3

    Thread Starter
    Fanatic Member jdc20181's Avatar
    Join Date
    Oct 2015
    Location
    Indiana
    Posts
    1,019

    Re: Is there a proper way to manage application size?

    Quote Originally Posted by jmcilhinney View Post
    There is a .NET Architecture & Design forum that is more appropriate for questions like this. I've asked the mods to move this thread there.

    There's no way to comment on your specific case without knowing more about it but things like included libraries and image resources are going to make your installation package bigger.
    Most likely its the images, which I can probably compress, I assume? There is a lot of stuff in the main project, vs the sub project.


    I have no clue what all is used its actually really messy because the project is over 2 years old, the new project was just started and uses much less external DLLS, only the essentials.

    The biggest one used is GeckoFX there is probably a dozen or so DLLS that are used for dependencies etc.

    Taking a second look, briefly it don't look like there is too much extra referenced anymore in the main project - and the couple libaries I remember using were pretty light it was the i00 spell check, and I forget the other, but both stopped meeting my needs/working appropriately, so they were moved a while back I am just boggled on what to do with the size, as I don't want to take up too much space.











    As far as moving the thread it would just be sending it into the virtual paper shredder the other sections of this forum end up dead. I have posted in other sections some of which my threads are the top threads waiting to be replied to. \_(ツ)_/ I mean it can be moved but its gonna kill the thread, and it is specifically tuned for VB.NET, not anything else.
    Disclaimer: When code is given for example - it is merely a example. See my First CodeBank Submission Upgrading to the newest IE when using the Webbrowser control See my Second CodeBank SubmissionVB.NET - Recording History or changes using WebbrowserControl RichTextBox Textbox
    See my Third codebank submission VB.NET - Detecting Secure/Insecure Websites (ssl) w/ Webbrowser control See CodeBank Submission 4 A Simple Large View Calendar Control See my browser project BeffsBrowser Try my SpeedTest Project

    Unless said otherwise (e.g. From one of my projects thus, those are mostly licensed under MIT) - All Code snippets advice or otherwise that I post on this site, are expressly licensed under Creative Commons Attribution 4.0 International Please respect my copyrights.

  4. #4
    PowerPoster
    Join Date
    Mar 2002
    Location
    UK
    Posts
    4,780

    Re: Is there a proper way to manage application size?

    You have not really elaborated on what's in your project. As an example, I have a solution with somewhere near 30 libraries, services, window forms, apps etc. This comes up at 120mb. Of that, 98mb is the help files and 15mb external libraries.. The coding part of a project is always small, hardly noticeable. Its the resources that make the space. If you have 100000 icons, or 100 bmp files it is going to bloat it. If you use jpgs instead it will cut down space. If you are using an external library and its 100mb, you don't have much choice but to either replace it or take the hit.

    You must know what is and what is not used. Its fairly easy to see, just clear out your bin folder and recompile (make sure you keep "other" files that you store in the bin folder....). There is a remove unused references button which you can take advantage of as well.

  5. #5
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    39,419

    Re: Is there a proper way to manage application size?

    Thread moved to the '.NET Architecture and Design' forum.
    Quote Originally Posted by jdc20181 View Post
    As far as moving the thread it would just be sending it into the virtual paper shredder the other sections of this forum end up dead. I have posted in other sections some of which my threads are the top threads waiting to be replied to. \_(ツ)_/ I mean it can be moved but its gonna kill the thread, and it is specifically tuned for VB.NET, not anything else.
    Most people who come here to help use the "New Posts" option (or an equivalent), so we find threads if they are in any of the forums we might help in.

    Whether threads get replies or not is not really affected by the forum they are in (as long as it is a valid forum for the question), it depends on various aspects of the thread, such as whether anybody knows anything about it (eg: it is rare to use any webbrowser, so GeckoFX isn't known by many) and whether it is interesting at all, and various other things.

    We have multiple forums because it makes more sense in many ways than putting every thread into one forum. For example: some people are much more likely to help in a specific forum that they are interested in (such as this one, or ASP.Net, or Database), rather than the generic VB.Net forum... and some of those people with a particular interest wont reply if the thread is in the 'wrong' forum.


    Most likely its the images, which I can probably compress, I assume?
    You can compress them by using appropriate file types for the images (such as png or jpg or gif), but which format will give the biggest reduction depends on each image. You can also do extra things in some cases, such as cropping images that have a single-colour border (and create the border when loading them using fairly simple code), or generating large pictures on the fly somehow using sub-pictures (assuming that most of the picture can be generated easily without using images).

    However, you shouldn't just assume it is the images and/or something else, you should find out exactly what the issues are (using Grimfort's advice or similar), otherwise you will end up wasting lots of time, and may make things worse (eg: building images on the fly could make a negligible size improvement, but make performance worse and build the images incorrectly in some cases).

  6. #6
    You don't want to know.
    Join Date
    Aug 2010
    Posts
    4,145

    Re: Is there a proper way to manage application size?

    Honestly I don't even know where the "new posts" thing is, and I don't want to see posts from 90% of the sub-forums. I click on "VB General" every visit and scroll down a little when bored.

    If it's so convenient, I've always wondered why we didn't stick a specific "Windows Forms" sub-forum below the fold where WPF is hidden. After all, "Windows Forms" is really a ".NET and More" topic, and if we want to categorize properly "VB General" should be where people ask questions like, "How do I add an event handler?" So we also need a ".NET General" for questions like, "What's the regex for this?", because there's nothing VB-specific about Regex.

    It turns out very few things in VB General are actually about VB and back when I was actually knee-deep in WPF it made me very frustrated it was shoved so far down.
    Nothing I post is production-ready. It is provided as-is, use it at your own risk.

  7. #7
    .NUT jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    97,077

    Re: Is there a proper way to manage application size?

    Quote Originally Posted by Sitten Spynne View Post
    Honestly I don't even know where the "new posts" thing is, and I don't want to see posts from 90% of the sub-forums.
    I'd suggest that you find it because you will miss some questions otherwise. I find it rare that something I would want to respond to isn't on the first page so it's not like you have to trawl through loads of dross to find the gems. I usually start with my UserCP page so that I can see my subscriptions with new posts first but even they show up clearly on the New Posts page so I'm not sure that even that's necessary. I'll follow that with the New Posts page and look for threads with zero replies and check whether they are in a forum I'm interested in, which would be anything .NET, Database Development and possibly some others if the title sounds interesting. I'll finish up with the VB.NET forum, just to make sure that I haven't missed anything.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

Posting Permissions

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



Featured


Click Here to Expand Forum to Full Width

Survey posted by VBForums.