Results 1 to 6 of 6

Thread: [RESOLVED] Attaching to a Program

  1. #1
    Junior Member
    Join Date
    Feb 12
    Location
    Las Vegas, NV
    Posts
    18

    Resolved [RESOLVED] Attaching to a Program

    I don't know if I am asking the question correctly, but I want to keep a program I use all the time in memory (running).

    So instead of closing the program (main form), I would like to simply set it's visible =false. This is easily done and works.

    Then on restart (I already know how to check to see if it is running) I would like to attach to it and make that running version's main form be visible again.

    Since this happens on many programs it's probably easy, and I am using the wrong wording when I search for "How to attach..."

    Thanks for your help.

  2. #2
    Web developer Nightwalker83's Avatar
    Join Date
    Dec 01
    Location
    Adelaide, Australia
    Posts
    9,836

    Re: Attaching to a Program

    Why do you need to keep the program in memory? That would clog up the bloat-ware of an operating system we call Windows even more.
    Last edited by Nightwalker83; May 5th, 2012 at 04:23 AM. Reason: Fixed spelling!
    If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
    Please consider giving me some rep points if I help you a lot.
    DON'T BUMP YOUR POSTS!!! Links to my code examples can now be found on my website: My websites
    Please rate my post if you find it helpful!
    Technology is a dangerous thing in the hands of an idiot! I am that idiot.

  3. #3
    Super Moderator si_the_geek's Avatar
    Join Date
    Jul 02
    Location
    Bristol, UK
    Posts
    35,624

    Re: Attaching to a Program

    Thread moved from the 'CodeBank VB.Net' forum (which is for you to post working code examples, not questions) to the 'VB.Net' forum

  4. #4
    PowerPoster
    Join Date
    Mar 02
    Location
    UK
    Posts
    4,063

    Re: Attaching to a Program

    Look up on how to create a system tray notification icon, that is, you essentially minimize the app down to an icon in the taskbar, and you can click it again to bring it back.

  5. #5
    Junior Member
    Join Date
    Feb 12
    Location
    Las Vegas, NV
    Posts
    18

    Re: Attaching to a Program

    Responding to Nightwalker: I have plenty of memory. I want this program available instantaneously. I use it for so many of the things I do all the time that It is like a desktop for me, yet I like to have my desktop with nothing but the pictures I have chosen which creates windows to the world for me.

    I have no problem with the complaint of Windows bloatware which you referenced. I remove everything I don't want.

    Note to si_the_geek: Sorry, it still is not apparent to me where to do what. I will work on that.

    Responding to GrimFort, Thank you, system Tray notification makes sense. Don't know why I did not think of it.

    For Everyone else, my workaround was to e.cancel in the formclosing event. While not as elegant as the system tray icon, it did the job. I put in a separate path to Quit the Program entirely. It just checked for the condition and skipped the e.cancel if executed.

  6. #6
    Junior Member
    Join Date
    Feb 12
    Location
    Las Vegas, NV
    Posts
    18

    Re: [RESOLVED] Attaching to a Program

    One final thing. I also set my program to be a "Single Instance Application" in the Application tab of "My Project". I also set it up so it will terminate if I right click on tool bar icon and "Close window" it.

    Now it functions like my personal "Metro" desktop with everything I want organized the way I want, available immediately when I want. And to top it off, I like it.

    Thank you for the clue GrimSoft, while I am not going to use the system tray notification icon, it led me to the single instance concept and ability to control what happens when you hit the X that normally would terminate the program.

Posting Permissions

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