Passing parameters to c++ (windows registry)
Hi everyone,
I want to run my c++ program with a context menu, so I created the pertinent key in the windows registry:
1 2
|
SOFTWARE\Classes\*\shell\Runmyprogram\command
value = "C:\Users\ntran\project\stpc.exe\" \"%1\"
|
In my c++ program I'll read the parameters with the
argv[]
variable.
Now it works fine, but now I want to add another perameter: "ncolor"
How do i modify the value in the registry to pass that parameter into my program?
Thanks
Last edited on
value = "C:/Users/ntran/project/stpc.exe\" \"%1\" ncolor"
Thanks for the simple concise answer, it worked.
Topic archived. No new replies allowed.