by Todd Geist

Watermark Photos with FileMaker

UPDATE! 4/2/2014 FMI just shipped 13.0v2.  This removes the limitation of having to self host when running the file locally on your computer. 

UPDATE! 8/8/2014 no longer requires Reactor on Windows.

UPDATE! 1/9/2015 cleaned up some old functions and documentation.

This module uses the HTML5 canvas element, Javascript, and FileMaker Web Viewer to watermark photos.  There is a video and full blog post describing how it is done on my website.

This works best on FileMaker 13, Mac and iOS.  To get it to work with Windows or on FileMaker 12 you will need the Free Reactor Lite plugin. See ReadMe for more details.

This image was watermarked with this Module.  pretty cool huh ? 🙂

Untitled 1



27 responses to “Watermark”

  1. […] the WebViewer and FileMaker you can do all sorts of cool things. In this video we look at a new ModularFileMaker Module I just released, called “Waterwark”. It uses HTML5 and Javascript to get […]

  2. Denis says:


    You deserve a big round of applause for spearheading a lot of wonderful things in FM: this site and the encouraged modules being one of them, all of the movies you’ve been putting up of late on your own site, and this module as well. Thanks for the great work.

  3. Karsten says:

    Very cool, Todd! 🙂

  4. George says:

    Can someone post a version that opens on 12 ??

    BIG Thanks!

    • Todd Geist says:

      Hi George,

      I posted a version that opens in 12. Remember you will need to use Reactor on FileMaker 12. Or you will need to be Hosting the file.



  5. Richard says:

    Really cool.
    I have no problem running this in Mac. But I have problem running in Window 7. I have FM Pro Advanced v3 installed. It always display “Error” in the container field. When I run the script, it give “Time Out” error. I installed the Reactor Plug-in as well. Do I need to set this up separately for this to run in Window ?

  6. Richard says:

    Thank you so much Todd. Now it works well with Windows. Can you share what have you change to make it works ? Cheers

    • Todd Geist says:

      Windows has two problems with calling scripts from a web viewer.

      1. The length of the parameter you pass back can’t be more than about 2000 characters.
      2. You can’t call a script when another FileMaker script is paused

      You can work around these two limitations. You can use the clipboard to pass the data back instead of a script parameter. And you have to avoid pausing.



  7. Richard says:

    Thank you so much, Todd. Really appreciate you take time to answer.

  8. Alec Gregory says:

    Hi Todd,

    I’d like to take a look at this, but the file seems to be corrupt. I get a file called WaterMark.fmp121.zip, which doesn’t seem to be a valid zip or fmp12 file.

    All the best,


  9. Shawn Flanagan says:

    The “GetFileURL” customer function is missing a function.


    useReactor = (mode = “reactor”);

    url = “fmp://” &
    Left(Get(FilePath);7) = “fmnet:/”; Get ( HostIPAddress ) ;
    ) & “/” & Get(FileName) ;

    url = Case(
    useReactor ; Let( t = ( “test” ; “ok” ) ; Left( t ; Position( t ; “/” ; 1 ; 4) -1 ) );



  10. Shawn Flanagan says:

    2. Copy the Custom Function “GetFileURL” into your file

    5. Copy the contents of the WaterMarking Layout in this file to the new Layout you made in step 2

    Step has nothing to do with a new layout.

  11. Shawn Flanagan says:

    // set this to the Field that has the HTML Code for this Widget

    HTML = “”

    Can find no reference to this field in the setup

    • Todd Geist says:

      Thanks for all the feedback. Where you able to get it to work? because two of the things you listed where just problems with the documentation, and the missing function is no longer needed.

      I uploaded a file that address the issues


  12. Justin Close says:

    Hey Todd,
    I was trying to re-purpose a bit of your code from this module, the bit where the Javascript makes a call back to the same DB file – the issue that was fixed in v13.02. I can’t seem to make it work, though. I posted a message with code on the Google group. Do you have some advice to provide on what I’m doing wrong? Here are the most relevant lines (maybe):

    eventResize: function(event, delta, revertFunc) {
    if (!confirm(event.title + ‘ end is now ‘ + ( event.end.format() ) + ‘.\n\nIs this okay?’)) {
    } else {
    fmpurl = ‘” & _fmpURLString & _fmScript1 & “&$eventid=’ + event.id + ‘&$newEndDate=’ + event.end ;
    httpXHR = new XMLHttpRequest();
    httpXHR.open(\”GET\”, fmpurl, true);

    I put in an alert in this function, and did see that, so I know it is at least getting into this function correctly.


    • Todd Geist says:

      Hi Justin,

      Can’t really tell what the issue is just looking at these lines. My advice would be to break it down into small chunks, and attack each chunk. First find out if you can call a script, then add a single parameter, then another parameter, etc, until you find where it stops working.

      you can also try moving the alert down the script until it stops. Then you’ll know what line is failing.

      Hope that helps



  13. Justin Close says:

    (Oh, there’s a combination of FileMaker and JavaScript quoting and escaping going on in that URL string.)

  14. Justin Close says:

    OK, so Todd got me straightened out; the XMLHTTPrequest form doesn’t work (currently…maybe in the future?), so if you don’t want to use a plugin, you have to use the ‘window.location=URL’ technique of JavaScript. But at least that works in a non-hosted version of a file running on the FMP client now. 🙂

  15. Tux Mac says:

    After following your directions to integrate into my own database, I’m getting this error: “The file “/.fmp12″ could not be opened. Either the host is not available, or the file is not available on that host.”

    Ideas on how to fix this error?

  16. Tux Mac says:

    yes, using 14 and yes, the example works great.

  17. Tux Mac says:

    i thought it may have something to do with the self hosting, but it looks like that is not required anymore, correct?

  18. Tux Mac says:

    Todd – any thoughts on either what is wrong or how to fix?


Leave a Reply

Your email address will not be published. Required fields are marked *