Results 1 to 5 of 5

Thread: [RESOLVED] VB 2010: Download to location of .exe

  1. #1

    Thread Starter
    Addicted Member HunterTTP's Avatar
    Join Date
    Jul 2012
    Posts
    146

    Resolved [RESOLVED] VB 2010: Download to location of .exe

    Alright so I would like my program to be just an .exe, this means I need it to download the Ionic.Zip.dll inside of the folder (location) that the exe is being ran from. I know how to download it, but I don't know how to get the folder that the .exe is in.

    Links or examples are much appreciated!





    HunterTTP

  2. #2
    Fanatic Member
    Join Date
    Jun 2008
    Posts
    1,023

    Re: VB 2010: Download to location of .exe

    Application.StartupPath

  3. #3

    Thread Starter
    Addicted Member HunterTTP's Avatar
    Join Date
    Jul 2012
    Posts
    146

    Resolved Re: VB 2010: Download to location of .exe

    Quote Originally Posted by Justa Lol View Post
    Application.StartupPath
    Thanks man that was exactly what I needed!

  4. #4
    PowerPoster JuggaloBrotha's Avatar
    Join Date
    Sep 2005
    Location
    Lansing, MI; USA
    Posts
    4,286

    Re: [RESOLVED] VB 2010: Download to location of .exe

    You do realize that if you have a dependency that's not present when the application starts, the app will crash even if the first thing the app does is check for it & download it as needed.
    This is one of the reasons to distribute your app with an installer, the installer can contain all of the needed files and put them where they're needed.
    Currently using VS 2015 Enterprise on Win10 Enterprise x64.

    CodeBank: All ThreadsColors ComboBoxFading & Gradient FormMoveItemListBox/MoveItemListViewMultilineListBoxMenuButtonToolStripCheckBoxStart with Windows

  5. #5

    Thread Starter
    Addicted Member HunterTTP's Avatar
    Join Date
    Jul 2012
    Posts
    146

    Re: [RESOLVED] VB 2010: Download to location of .exe

    Actually the program does not crash until it starts the Private Sub which requires the dependency. So when you click "install" I have it download the dependency with the button click, then start the background worker (which uses the .dll) and it works just fine. The only problem I am having now is I want it to delete the dependency once the background worker is finished. I do not think that is possible because, once the dependency is loaded, it is not unloaded until the program is closed.
    Last edited by HunterTTP; Aug 6th, 2012 at 12:29 PM.

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