CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 5 of 5

Thread: how to do this?

  1. #1
    Join Date
    May 2009
    Posts
    3

    how to do this?

    how would i go about changing the way an .exe program opens? like say the _main_ .exe i wanted to open could only be opened by opening another .exe program before you could open the _main_ .exe, how would i go about to do this?

  2. #2
    Join Date
    Jul 2005
    Location
    Netherlands
    Posts
    2,042

    Re: how to do this?

    You could send some verification key as a command line argument to the program. If the key is incorrect, you exit. But if it's correct then it must have been called from the other application.

    The real question is, of course, why would you want to do this? Having an application that cannot be started by the user does not make sense. Can't you use a dll instead?
    Cheers, D Drmmr

    Please put [code][/code] tags around your code to preserve indentation and make it more readable.

    As long as man ascribes to himself what is merely a posibility, he will not work for the attainment of it. - P. D. Ouspensky

  3. #3
    Join Date
    May 2009
    Posts
    3

    Re: how to do this?

    the _main_ .exe will be the main program, however they would need to update their client therefore would have to use a kind of update program so they get the updates before going to the _main_ .exe which is what am i trying to do

    I intend to enter a password / key to be entered by the first program onto the _main_ .exe, but i am really new to this kind of stuff, therefore would you let me know how i would start to go about this?

  4. #4
    Join Date
    Jun 2007
    Posts
    24

    Re: how to do this?

    Your looking at it the wrong way this is how you could do it..

    -main.exe loads up
    -A window appears an asks for Login
    -Program checks for Update: if needed it downloads the updates
    -Windows goes away an is replaced with the main page, or whatever

  5. #5
    Join Date
    Nov 2003
    Location
    Belgium
    Posts
    8,150

    Re: how to do this?

    [ removed duplicate thread ]
    Marc Gregoire - NuonSoft (http://www.nuonsoft.com)
    My Blog
    Wallpaper Cycler 3.5.0.97

    Author of Professional C++, 4th Edition by Wiley/Wrox (includes C++17 features)
    ISBN: 978-1-119-42130-6
    [ http://www.facebook.com/professionalcpp ]

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

Featured