With QTP it is easy to save a selected picture in the MS File Explorer as a picture in the clipboard using a keyboard shortcut!
1.) ... Defining and using the shortcut for Image to clipboard!
2.) ... What is the advantage compared to opening MS Paint and copying, for example?
3.) ... How does it work that the picture ends up in the clipboard via keyboard shortcut?
Explanation of sub-item in: ► New system commands in QTP for MS Windows OS!
1.) Defining and using the shortcut for Image to clipboard!1. Start as always ► Quick-Text-Paste for MS Windows!
2. Define the command for a shortcut in Quick Text Paste sys:ImgToClipboard
(PS: Here in the example the Ctrl+Atl+C shortcut)
(... see Image-1 Point 1 to 3)
3. For testing, mark a picture in the MS Explorer or Quad Explorer , ....
4. And test the keyboard shortcut
Mark the picture in the file explorer, use Ctrl+Atl+C, then you can now paste it into any program with Ctrl + V!
|(Image-1) Save the image to the clipboard using a keyboard shortcut!|
2.) What is the advantage over the detour, e.g. open MS Paint and copy?It can also be done via MS Paint, but it requires a lot more manipulations. MS Paint and many other image processing programs do not handle the image transparency in the clipboard correctly, which can be very important especially with MS Office, Open Office, ...
(... see Image-2 Point 1 and 2)
But the essential factor is the time saving ;-)
|(Image-2) Image in MS Excel via QTP and via MS Paint Transparency is missing in the image!|
3.) How does it work that the picture ends up in the clipboard via keyboard shortcut?
1. You mark the relevant picture in MS Explorer or Quad Explorer , .... etc.
2. Press the keyboard shortcut you have predefined
3. Now the command Copy is sent to the appropriate File Explorer
4. Quick-Text-Paste for MS Windows interprets the path and places the picture as a graphic in the clipboard
5. Now you can paste it into any X program, APP, using Ctrl + V that has the clipboard function
As described under ... point 2 !
Is an extension of the old function: ► Keyboard shortcuts to insert a signature in WordPad!
|(Image-3) So that the image ends up in the clipboard via a keyboard shortcut|