This script allows screen captures (or any copied image) to be pasted into a OneNote table with automatic resizing enabled - so the image won't mess up your table and the images will scale when the table size is changed! Alternatively, you could also use this script to paste images from your clipboard into any directory.
AutoHotKey (AHK) v1.1 script: automatically saves screen captures from Windows+Shift+S (or every image copied to the clipboard - see options) to a file and then adds the file path to the clipboard.
Uses WinClip class: AHK forum post, Website.
-
Install AHK v1.1 (not V1.0, not V2) from https://www.autohotkey.com/
-
(Optional) Edit options in Clipboard.ahk (global variables at the top of the file)
e.g. with ALL_IMAGES = true and REQUIRE_CTRL = true, the script will place every image as a file into the clipboard, so you can also paste the image as a file into any directory in Explorer, but only when you hold down the Control key.
-
Run script - you can now use Win+Shift+S to take a screen snip and then just paste it into OneNote! If you haven't changed the options (step 2), you will get a tooltip like this if the script is running:
-
(Optional) To make the script run on Windows startup, create a shortcut to the script in the Startup folder (shell:startup).