I've looked everywhere but only found solutions revolving online images. I'm dealing with a local image with this directory: C:\Users\ME\Desktop\Venice.jpg
I need some Javascript or vbScript to simply set that image itself (not the path) into the clipboard, so that I can paste the image into an application like Word or MS Paint.
I've found the following code, but don't know how to adapt it for my use. There is no internet access required. A simple, local javascript function is all I need. I have no applicable html so I don't see what to substitute "div" with below. Any help is great!! Thank you.
var div = document.getElementById('DivtoCopy');
div.contentEditable = 'true';
var controlRange;
if (document.body.createControlRange) {
controlRange = document.body.createControlRange();
controlRange.addElement(div);
controlRange.execCommand('Copy');
}
div.contentEditable = 'false';