Upload Image

Verb: loadImage

Uploads an image file or an internet image via a URL to a variable.


loadImage --file(String) (Image)=value


Script Designer Required AcceptedTypes Description
--file File Required Text Full path of the image file or URL of the internet hosted image that should be uploaded.


Script Designer AcceptedTypes Description
value Image Image Returns the loaded image assigned to a variable.


Example 1: A new image is loaded, based on an image file, and assigned to the "loadedImage" variable.

defVar --name loadedImage --type Image
// Download the image file to insert it in the "file" parameter.
loadImage --file "imageForLoading.png" loadedImage=value

Example 2: Upload a new image from the Internet in a variable of type "Image"

defVar --name loadedImage --type Image
loadImage --file "https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcRt0Wl8ennSek_VmhnCXgi-_lR9_fpt1XFjuwGKCl-EQ5CEXiq1&s" loadedImage=value
logMessage --message "${loadedImage}" --type "Info"

Download File

For the correct operation of the script above, it is necessary to download the image and insert it in the File parameter of the Upload Image command.


The variable of type "Image" can be viewed and inspected through the global variables by running the script in debug mode.

See Also

  • Crop Image
  • Save Image