Thread: Compiling and running a single file

  1. #1
    Registered User
    Join Date
    Feb 2006
    Posts
    1

    Compiling and running a single file

    Is it possible to compile and execute a single cpp file on my hard disk from Visual Studio .NET 2005, without going through the full process of creating a new project, etc.?
    Thanks!

  2. #2
    Tropical Coder Darryl's Avatar
    Join Date
    Mar 2005
    Location
    Cayman Islands
    Posts
    503
    Short answer, No. Best advice I can give you is this: Keep an empty project handy, and add your files to project as needed.

  3. #3
    Registered User
    Join Date
    Apr 2003
    Posts
    2,663
    Best advice I can give you is this: Keep an empty project handy, and add your files to project as needed.
    Yep, it's my standard practice to have 3 or 4 test projects that I use to try different things without having to go through the hassle of creating a new project every time I want to test some code.

  4. #4
    Confused Magos's Avatar
    Join Date
    Sep 2001
    Location
    Sweden
    Posts
    3,145
    Using the wizards it doesn't take THAT much time to create a new project...
    MagosX.com

    Give a man a fish and you feed him for a day.
    Teach a man to fish and you feed him for a lifetime.

  5. #5
    ---
    Join Date
    May 2004
    Posts
    1,379
    run the compiler from the command line

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Problem Running Program After Compiling
    By kristentx in forum C++ Programming
    Replies: 13
    Last Post: 09-12-2007, 10:46 AM
  2. #include header files or .cpp files?
    By DoctorX in forum C++ Programming
    Replies: 3
    Last Post: 12-23-2006, 12:21 PM
  3. help compiling genome assemblers
    By bluegirl in forum C Programming
    Replies: 1
    Last Post: 03-29-2006, 03:25 PM
  4. File I/O problem
    By dacbo in forum C Programming
    Replies: 4
    Last Post: 01-17-2006, 08:22 AM
  5. fputs and sequential file
    By sballew in forum C Programming
    Replies: 5
    Last Post: 11-11-2001, 04:48 PM