GIDForums

Go Back   GIDForums > Computer Programming Forums > MS Visual C++ / MFC Forum
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read


 
 
Thread Tools Search this Thread Rate Thread
  #1  
Old 20-Nov-2007, 14:00
swedenguy swedenguy is offline
New Member
 
Join Date: Aug 2006
Posts: 8
swedenguy is on a distinguished road

How to read an argument from the terminal in visual c++ studio


hi everybody!
I have made some searching in google about this problem but could not find an answer
My problem is following:
I want to read the name of a file when i run a program in visual c++ express studio
fp = fopen(argv[1], "r"); // the name of the program, read from terminal
in linux i know how to do but in visual studio it seems more complex
The only thing i can see in the visual studio is start debuging and start without debuging.
Is there any way to read a value from terminal (like a filename fo example) when you run a program in visual c++ express studio?
  #2  
Old 20-Nov-2007, 15:32
davekw7x davekw7x is offline
Outstanding Member
 
Join Date: Feb 2004
Location: Left Coast, USA
Posts: 4,520
davekw7x is a splendid one to beholddavekw7x is a splendid one to beholddavekw7x is a splendid one to beholddavekw7x is a splendid one to beholddavekw7x is a splendid one to beholddavekw7x is a splendid one to beholddavekw7x is a splendid one to behold

Re: how to read an argument from the terminal in visual c++ studio


Quote:
Originally Posted by swedenguy
Is there any way to read a value from terminal (like a filename fo example) when you run a program in visual c++ express studio?

Under the project properties there is a "Configuration Properties" topic.

There is a list item under "Debugging" called "command arguments". Put your command line stuff there.

Details vary slightly with different versions of Visual Studio, so if you can't find it, then post again and tell us what version you are using. Maybe someone has the same version and can walk you through it step-by-step.

Regards,

Dave
 

Recent GIDBlogNew Corolla Altis, 10th Generation - Part I by Nihal

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Multiple questions for C++ project devster420 CPP / C++ Forum 1 20-Apr-2007 21:26
Major newbie problem cynack MS Visual C++ / MFC Forum 1 08-Apr-2007 11:25
something simple (I think) dagiffy CPP / C++ Forum 1 21-Jan-2007 22:10
How Visual C++ only from Visual Studio .net Picstudent .NET Forum 2 28-May-2006 20:52
What is "Ambigious symbol" ??*( a compilation error) small_ticket CPP / C++ Forum 2 07-Jan-2005 21:10

Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The

All times are GMT -6. The time now is 18:45.


vBulletin, Copyright © 2000 - 2008, Jelsoft Enterprises Ltd.