Results 1 to 7 of 7

Thread: Odd question

  1. #1
    Join Date
    Aug 2007
    Location
    In a hole
    Posts
    85

    Odd question

    So I have been working with c++ for a while but I never really got around to understanding how to make a program that I could run without having to open up VS2008 and compile. I want to make a simple program that when I open windows, it will ask me if I have done such and such tasks.
    I am not asking for the code, but primarily the steps in which I could get this done. I know the startup part deals with registry but and advice would help.
    Thanks in advance.

  2. #2
    Join Date
    Mar 2006
    Location
    South Australia
    Posts
    4,521
    Well, once you have written your program, compile a release build. Inside your project folder hierarchy find the compiled program and save it somewhere. Then just create a shortcut to the program in the Startup program group, and the program will run each time you reboot.

  3. #3
    Join Date
    Nov 2006
    Location
    UK
    Posts
    3,774
    As Mr_charisma says, when you compile your program hidden in your project folder will be a debug and release folder - in there is an exe for you to do with as you will - including give to your friends (and enemys) etc.

    For launching on startup, you either as mr_charisma says want to put it in the startup group in your (or all users) start menu, or, you can place it to run in one of a number of registry keys.

    Code:
    For the registry keys for the current user account you can put an entry in 
    HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run
    
    for all users 
    HKEY_USERS\.DEFAULT\Software\Microsoft\Windows\CurrentVersion\Run
    There are no spaces if it insists on putting them in I tried editing it to stop it but it wouldnt play
    Delphi !ROCKS!
    Got a question? Read this first!!!
    "You gotta help us, Doc. We've tried nothin' and we're all out of ideas"

  4. #4
    Join Date
    Aug 2007
    Location
    In a hole
    Posts
    85
    Thanks for the replies! I checked in the folder and the exe was titled <q>blah.exe.manifest</q> I am not sure exactly what that means or what to do.

    And thank you very much for the registry advice! I wasn't even expecting it.

  5. #5
    Join Date
    Jun 2005
    Location
    NY
    Posts
    1,374
    The manifest is not waht you're seeking. That simply describes things about your application. You want the plain exe file. If you don't know where to look, go into the project options in Visual Studio for the project, and in the Linker->General tab, there should be a option called "Output File" the value might look like "$(OutDir)\$(ProjectName).exe" click on the arrow in that combo box and choose "<edit...>" then cleick the button "Macros>> " in the window that pops up, this will let you see the value of all the macros. Look at what "OutDir" is and you'll find the exe at that directory.
    CodeGuru: DLL Tutorial For Beginners by me. Rated 4 1/2 out of 5.

  6. #6
    Join Date
    Nov 2006
    Location
    UK
    Posts
    3,774
    Manifest is like a readme for the computer, it tells it stuff about it - there should be in there also a .exe proper.
    Delphi !ROCKS!
    Got a question? Read this first!!!
    "You gotta help us, Doc. We've tried nothin' and we're all out of ideas"

  7. #7
    Join Date
    Aug 2007
    Location
    In a hole
    Posts
    85
    Oh now I see it, thanks again guys!

Posting Permissions

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