Click here to Skip to main content
15,916,462 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionHow to get an item by its text in a tree view? Pin
KellyR8-May-07 9:09
KellyR8-May-07 9:09 
AnswerRe: How to get an item by its text in a tree view? Pin
Mark Salsbery8-May-07 9:42
Mark Salsbery8-May-07 9:42 
GeneralRe: How to get an item by its text in a tree view? Pin
KellyR8-May-07 10:03
KellyR8-May-07 10:03 
QuestionConvert CString tou double (not always...) Pin
johnny__XP8-May-07 9:04
johnny__XP8-May-07 9:04 
AnswerRe: Convert CString tou double (not always...) Pin
Hans Dietrich8-May-07 9:23
mentorHans Dietrich8-May-07 9:23 
AnswerRe: Convert CString tou double (not always...) Pin
ThatsAlok8-May-07 21:15
ThatsAlok8-May-07 21:15 
AnswerRe: Convert CString tou double (not always...) Pin
ThatsAlok16-May-07 20:26
ThatsAlok16-May-07 20:26 
QuestionMain Arguments Pin
TheDelChop8-May-07 8:51
TheDelChop8-May-07 8:51 
Hi guys,

I am writing a simple program that the user would like to be able to run from the command prompt. I am wondering how I pass that infromation into the main of my program. For example, if you wish to run Windows explorer from the command line you pass the command "explorer". This will launch Windows explorer and default to showing C:\. However, you can also call explorer and have it open a specific directory "explorer C:\Test\MyTest".

My question is this:

Is the second part of that simply passed as the argument to main? For example if I wanted my program to specify a string, could I have my main function accept a const char *?

I.E. void main(const char *inputString) ?

where inputString would be whatever it is that I have passed immediately after my *.exe name?

so the total call would be something like:

C:\> stringParser This Is My Test

which would hopefully pass a pointer to "This is My Test" into my main argument.

Thanks,

Joe
AnswerRe: Main Arguments Pin
Mark Salsbery8-May-07 9:30
Mark Salsbery8-May-07 9:30 
GeneralRe: Main Arguments Pin
toxcct8-May-07 13:37
toxcct8-May-07 13:37 
GeneralRe: Main Arguments Pin
Mark Salsbery8-May-07 13:45
Mark Salsbery8-May-07 13:45 
AnswerRe: Main Arguments Pin
ThatsAlok16-May-07 20:26
ThatsAlok16-May-07 20:26 
QuestionC#.net to C++ (simple code conversion) ? Pin
Software_Specialist8-May-07 8:39
Software_Specialist8-May-07 8:39 
AnswerRe: C#.net to C++ (simple code conversion) ? Pin
Hamid_RT8-May-07 9:02
Hamid_RT8-May-07 9:02 
GeneralRe: C#.net to C++ (simple code conversion) ? Pin
Software_Specialist8-May-07 9:09
Software_Specialist8-May-07 9:09 
GeneralRe: C#.net to C++ (simple code conversion) ? Pin
Hamid_RT8-May-07 9:21
Hamid_RT8-May-07 9:21 
AnswerRe: C#.net to C++ (simple code conversion) ? Pin
Mark Salsbery8-May-07 9:22
Mark Salsbery8-May-07 9:22 
GeneralRe: C#.net to C++ (simple code conversion) ? Pin
Software_Specialist8-May-07 10:09
Software_Specialist8-May-07 10:09 
GeneralRe: C#.net to C++ (simple code conversion) ? Pin
Mark Salsbery8-May-07 10:37
Mark Salsbery8-May-07 10:37 
Questioncancel dialog Pin
deeps_cute8-May-07 7:52
deeps_cute8-May-07 7:52 
AnswerRe: cancel dialog Pin
Cedric Moonen8-May-07 7:53
Cedric Moonen8-May-07 7:53 
GeneralRe: cancel dialog Pin
deeps_cute8-May-07 7:58
deeps_cute8-May-07 7:58 
QuestionRe: cancel dialog Pin
David Crow8-May-07 8:11
David Crow8-May-07 8:11 
GeneralRe: cancel dialog Pin
Hamid_RT8-May-07 8:52
Hamid_RT8-May-07 8:52 
AnswerRe: cancel dialog Pin
KellyR8-May-07 10:56
KellyR8-May-07 10:56 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.