Results 1 to 7 of 7

Thread: [RESOLVED] Include .NET Framework in app

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    Apr 2016
    Posts
    1,415

    Resolved [RESOLVED] Include .NET Framework in app

    Hi , I have now using VS2017 community and some things seems to be working different. I have .NET Framework 4.6.1 as prerequisite. What I want to do is for users not to have to go download .NET framework themselves. When I "build" the project and go to release folder everything must be there. User must just click on my app .exe and it must work. The reason for not want to use "setup" method for install the app is because we don't have admin access to install software. How to automatically include this .NET framework in app? At the moment on my PC if I click .exe then is working. If I do that on other PC that not have .NET framework installed, then gives error...

    Thanks...

  2. #2
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    39,039

    Re: Include .NET Framework in app

    I would have thought that this wasn't possible, but there are two responses on here that suggest a way that may or may not work for you:

    https://stackoverflow.com/questions/...o-admin-rights
    My usual boring signature: Nothing

  3. #3
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 2002
    Location
    Bristol, UK
    Posts
    41,930

    Re: Include .NET Framework in app

    The .Net framework requires installation, and realistically it is too large to be included with an application anyway.

    What you can probably do is select an earlier .Net framework version in your project (as VS2017 allows you to pick which one), assuming of course that you know the users will have a particular version, and that you don't need the newer features (based on your previous threads, you probably don't).

  4. #4
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    110,344

    Re: Include .NET Framework in app

    You should create an installer for your app and have it install the Framework if it isn't already. It's exactly this sort of thing that installers are for.

  5. #5

    Thread Starter
    Frenzied Member
    Join Date
    Apr 2016
    Posts
    1,415

    Re: Include .NET Framework in app

    okay i revert back to older .NET and is working now. Thank you

  6. #6
    Super Moderator Shaggy Hiker's Avatar
    Join Date
    Aug 2002
    Location
    Idaho
    Posts
    39,039

    Re: [RESOLVED] Include .NET Framework in app

    Various versions of the framework come pre-installed on different versions of the OS. Most likely, the reason it is working is that you have dropped back to a version that was already installed on the computer in question. This will work as long as the only people using the program are people running an OS that has the framework already installed. That may well be a safe assumption, based on what you have said.
    My usual boring signature: Nothing

  7. #7
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    110,344

    Re: [RESOLVED] Include .NET Framework in app

    How old did you go? Note that Windows 10 (more recent versions, at least) have .NET 4.x installed by default but not .NET 3.5 (which includes 3.0 and 2.0) so it will not be a safe assumption that all users will have a .NET version earlier than 4.0 installed. Older versions of Windows will have .NET 3.5 installed by default but not 4.x, so 4.0 or later is not a safe assumption either. Older versions still may not have any .NET version installed by default. Unless you know that your users will always have a specific version installed, you should create an installer for your app that checks for and installs the version you require as part of the application installation.

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