The 'Resize an Image' flow action resizes the image provided to the specified configuration. Images can be resized to a percentage of the current image dimensions or specific dimensions, optionally selecting to preserve the image aspect ratio.
Please refer to the following article detailing how to use the Encodian 'Compress an Image' and 'Resize an Image' actions to reduce the size of image files generated within PowerApps using Microsoft Flow: Reduce the size of images generated by PowerApps with Flow
Supported File Types
The following image files types are supported by this action.
The default 'Resize an Image' flow action parameters are detailed below:
- Filename: The image filename to be processed (including file extension).
- File Content: A Base64 encoded representation of the image file to be processed.
- Resize Type: Sets whether the image should be resized using the value of the 'Resize Percentage' field, or whether the image should be resized using the values of the 'Image Width' and 'Image Height' fields.
- Resize Percentage: Sets the percentage value for resizing the image. For example; 10 is equal to 10%, 120 is equal to 120%. This field is only used when the 'Resize Type' field is set to 'Percentage'.
- Image Width: Set a specific image width in pixels. This field is only used when the 'Resize Type' field is set to 'Specific'.
- Image Height: Set a specific image height in pixels. This field is only used when the 'Resize Type' field is set to 'Specific'.
- Maintain Aspect Ratio: If 'True', the image height value is automatically determined based on the 'Image Width' field, if a value is provided within the 'Image Height' field it will be ignored. This field is only used when the 'Resize Type' field is set to 'Specific'.
Please refer to the Obtaining the 'File Contents' Parameter article for guidance on how to obtain the 'File Content' parameter ready to provide to an Encodian flow action.
The 'Resize an Image' flow action returns the following data.
Standard Return Values
- Filename - The filename of the document.
- FileContent - The processed image file.
- OperationId - The unique ID assigned to this operation.
- HttpStatusCode - The HTTP Status code for the response.
- HttpStatusMessage - The HTTP Status message for the response.
- Errors - An array of error messages should an error occur.
- Operation Status - Indicates whether the operation has completed, has been queued or has failed.