| Components | All | New | MacOS | Windows | Linux | iOS | ||||
| Examples | Mac & Win | Server | Client | Guides | Statistic | FMM | Blog | Deprecated | Old | |
GMImage.WriteToWebPContainer
Writes the picture in WebP format to a container value which you can store in a container field.
| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
| GraphicsMagick | 13.2 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |
MBS( "GMImage.WriteToWebPContainer"; ImageRef { ; FileName } ) More
Parameters
| Parameter | Description | Example | Flags |
|---|---|---|---|
| ImageRef | The image reference number. | 1 | |
| FileName | The file name to use for the container. Default is "image.webp" |
"ball.webp" | Optional |
Result
Returns a container value.
Description
Writes the picture in WebP format to a container value which you can store in a container field.For FileMaker 26 stores WEBP with JPEG preview. For older FileMaker versions we store FILE with JPEG preview.
See also GMImage.WriteToFile, GMImage.WriteToJPEGContainer, GMImage.WriteToPNGContainer, GMImage.WriteToBMPContainer and GMImage.WriteToGIFContainer.
Examples
Convert to WebP:
# Load from container
Set Variable [ $Image ; Value: MBS("GMImage.NewFromContainer"; Image Scaling::InputImage) ]
If [ MBS("IsError") ]
Show Custom Dialog [ "Error" ; $Image ]
Exit Script [ Text Result: ]
Else
# Write image to container and set the Information text
Set Field [ Image Scaling::Result ; MBS("GMImage.WriteToWebPContainer"; $Image; "test.webp") ]
# Release image
Set Variable [ $r ; Value: MBS("GMImage.Free";$Image) ]
End If
Set Variable [ $Image ; Value: MBS("GMImage.NewFromContainer"; Image Scaling::InputImage) ]
If [ MBS("IsError") ]
Show Custom Dialog [ "Error" ; $Image ]
Exit Script [ Text Result: ]
Else
# Write image to container and set the Information text
Set Field [ Image Scaling::Result ; MBS("GMImage.WriteToWebPContainer"; $Image; "test.webp") ]
# Release image
Set Variable [ $r ; Value: MBS("GMImage.Free";$Image) ]
End If
See also
- GMImage.Free
- GMImage.New
- GMImage.NewFromContainer
- GMImage.WriteToBMPContainer
- GMImage.WriteToContainer
- GMImage.WriteToFile
- GMImage.WriteToGIFContainer
- GMImage.WriteToPDFContainer
- GMImage.WriteToTiffContainer
- IsError
Release notes
- Version 16.3
- Improved GMImage.WriteToWebPContainer to write WEBP containers instead of FILE containers in FileMaker 26.
- Version 13.2
- Added GMImage.WriteToWebPContainer function.
Blog Entries
- MBS FileMaker Plugin, version 16.3pr4
- New in MBS FileMaker Plugin 13.2
- MBS FileMaker Plugin, version 13.2pr1
This function checks for a license.
Created 23th March 2023, last changed 29th June 2026
MarkDown version: GMImageWriteToWebPContainer.md