N
N
NikClik2018-10-09 00:49:20
C++ / C#
NikClik, 2018-10-09 00:49:20

How to get data when calling a program from the context menu?

I am writing an application in C ++, the bottom line is that using the registry, I shoved my program into the context menu for folders (I will explain using Git Bash Here as an example), it looks something like this:
5bbbc89fcccc7173543990.png
In the registry, the structure looks something like this:
5bbbc97ab5bae468512018.png5bbbc994ddd24726267449.png
and as we see in The command value indicates where to run the program from ("C:\Program Files\Git\git-bash.exe") and, as I understand it, pass the full path of the folder from which this program was called ("--cd=%v. "). So, please explain to me how to programmatically take this path ("--cd=%v."), when calling the program using the context menu?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
J
jcmvbkbc, 2018-10-09
@NikClik

I am writing an application in C ++...
how to take, when calling a program using the context menu, the full path from where this program is called ("--cd=%v.")

From the argv parameter of the main function .

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question