I'm making a program in C# using WinForms. When user presses a combination of keys, e. g. SHIFT+A, my program determines that - I already setup that with a keyboard hook.
What I need is that program knows what is selected or marked such as text, image, app etc. When a user presses SHIFT+A, what is selected program save into a created file in directory which is already done. How do I get the selected control into the created file? How do I get what is selected into a text file and save it or write the marked control into the created file.
I tried to find the answer on the internet, but there are only answers for the TextBox control.