# Combined Components with MBS FileMaker Plugin

**URL:** <https://the.fmsoup.org/t/combined-components-with-mbs-filemaker-plugin/1989>\
**Category:** MBS Plugins\
**Tags:** integration\
**Created:** [April 2, 2021, 8:16am UTC](https://the.fmsoup.org/t/combined-components-with-mbs-filemaker-plugin/1989 "2021-04-02T08:16:56Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![MonkeybreadSoftware](https://yyz2.discourse-cdn.com/flex030/user_avatar/the.fmsoup.org/monkeybreadsoftware/32/361_2.png) [@MonkeybreadSoftware](https://the.fmsoup.org/u/MonkeybreadSoftware)\
**Post date:** [April 2, 2021, 8:16am UTC](https://the.fmsoup.org/t/combined-components-with-mbs-filemaker-plugin/1989/1 "2021-04-02T08:16:56Z")

</div>

When using [MBS FileMaker Plugin](https://www.monkeybreadsoftware.com/filemaker/), you may need to combine a lot of functions together to get some work done. That makes our toolbox of functions so flexible to use for your needs. Let us show you four examples:

#### Regularly import files from hot folder

- First you start with [Schedule](https://www.mbsplugins.eu/component_Schedule.shtml) functions to run a script regularly every few minutes in FileMaker Pro. Independent of SetTimer script step, so you can have multiple of them.
- You look into a file path with [Files.List](https://www.mbsplugins.eu/FilesList.shtml) to get a list of file names in the folder.
- By using our [List](https://www.mbsplugins.eu/component_List.shtml) functions you compare the current file list to the one from last run. For example [List.And](https://www.mbsplugins.eu/ListAnd.shtml) would find similar files in both files, while [List.FindUnequals](https://www.mbsplugins.eu/ListFindUnequals.shtml) would find the ones different.
- Next you use [Path](https://www.mbsplugins.eu/component_Path.shtml) functions to build file path by taking folder path and the file name. Use [Path.AddPathComponent](https://www.mbsplugins.eu/PathAddPathComponent.shtml) to not care about slash vs. backslash.
- A function like [Hash.DigestFile](https://www.mbsplugins.eu/HashDigestFile.shtml) may quickly get you a SHA512 secure hash of the file.
- You can do a search in FileMaker to check whether the hash is known. Or use our [FMSQL](https://www.mbsplugins.eu/component_FMSQL.shtml) functions to do the check with a [FM.ExecuteFileSQL](https://www.mbsplugins.eu/FMExecuteFileSQL.shtml) call to do a "SELECT COUNT(\*) WHERE hash=?" SQL query to count the records and either get back 0 or 1.
- To read the file you may use [Container.ReadFile](https://www.mbsplugins.eu/ContainerReadFile.shtml) function and get it in a variable first.
- You can then create a new record for the file with FileMaker script steps. Or you use [FM.InsertRecord](https://www.mbsplugins.eu/FMInsertRecord.shtml) to create record for it without switching layout.
- If you do a document database, you may go for a PDF document and use our [PDFKit](https://www.mbsplugins.eu/component_PDFKit.shtml) functions or [DynaPDF](https://www.mbsplugins.eu/component_DynaPDF.shtml) functions to extract text for PDF, maybe split the PDF and make preview pictures for the pages.
- For image files, you may use [GraphicsMagick](https://www.mbsplugins.eu/component_GraphicsMagick.shtml) functions or [CGImageSource](https://www.mbsplugins.eu/component_CGImageSource.shtml) functions to extract metadata for image files like camera model or GPS coordinates.

#### Scan documents and upload them

- On Windows you can use [WIA](https://www.mbsplugins.eu/component_WIA.shtml) functions to scan documents including the use of a document feeder.
- On macOS we have [ImageCapture](https://www.mbsplugins.eu/component_ImageCapture.shtml) functions to use scanners, but also import from a digital camera, which you can even trigger to take a picture if you have it connected via USB.
- You can use our [GraphicsMagick](https://www.mbsplugins.eu/component_GraphicsMagick.shtml) functions to check whether a page is all white to remove it.
- Use [DynaPDF](https://www.mbsplugins.eu/component_DynaPDF.shtml) functions to build PDF document from pages.
- Finally use [CURL](https://www.mbsplugins.eu/component_CURL.shtml) functions do upload the document via SFTP to a server or use AWS S3 or Dropbox for this.

 ![](https://www.mbs-plugins.com/images/scandialog.jpg)

#### Drag & drop import of video files and prepare previews

- Check the [DragDrop](https://www.mbsplugins.eu/component_DragDrop.shtml) functions provide drop area to your users.
- User drops video file on the layout, a script is triggered and in the script you check the files.
- Check file type and filter to only video files.
- Use [AVAsset](https://www.mbsplugins.eu/component_AVAsset.shtml) functions to load video on macOS or iOS.
- Check duration, create new record for video.
- Loop from 1 to 10 and create ten preview pictures for video frames at 10 points in time in video with [AVAsset.Image](https://www.mbsplugins.eu/AVAssetImage.shtml) function.
- Scale first picture down with [GraphicsMagick](https://www.mbsplugins.eu/component_GraphicsMagick.shtml) functions to store as thumbnail.
- Allow user to playback video with [AVPlayer](https://www.mbsplugins.eu/component_AVPlayer.shtml) functions on macOS/iOS or [WMFP](https://www.mbsplugins.eu/component_WMFP.shtml) functions on Windows.

 ![](https://www.mbs-plugins.com/image/DragDropPopover.jpg)

#### Build Invoice and send via email

- Output invoice in FileMaker with Save as PDF script step.
- Load with [DynaPDF](https://www.mbsplugins.eu/component_DynaPDF.shtml) functions
- Add terms of conditions PDF to the end.
- Add page numbers (see examples).
- Search pages with [DynaPDF.FindText](https://www.mbsplugins.eu/DynaPDFFindText.shtml) function for company website URL and make those clickable links with [DynaPDF.WebLink](https://www.mbsplugins.eu/DynaPDFWebLink.shtml).
- Add payment barcode (EPC for example) to invoice with our [Barcode](https://www.mbsplugins.eu/component_Barcode.shtml) functions or better as vector graphics with newer DynaPDF.DrawBarcode function.
- Convert to PDF/A file.
- Digitally sign the PDF with your signature with [DynaPDF.SaveAndSignFile](https://www.mbsplugins.eu/DynaPDFSaveAndSignFile.shtml) function.
- Use [SendMail](https://www.mbsplugins.eu/component_SendMail.shtml) functions to build email with HTML.
- Use [Text.MergeFields](https://www.mbsplugins.eu/TextMergeFields.shtml) to prepare HTML and fill in fields from customer record.
- Add PDF as attachment with [SendMail.AddAttachmentContainer](https://www.mbsplugins.eu/SendMailAddAttachmentContainer.shtml) function.
- Send Email via [CURL](https://www.mbsplugins.eu/component_CURL.shtml) functions. This may include a custom header in the email to easier detect bounces.
- Check debug messages from CURL from mail server to record email as sent successfully.
- Optional have [CURL](https://www.mbsplugins.eu/component_CURL.shtml) functions use with IMAP example to monitor mailbox for bounces.

 ![](https://www.mbs-plugins.com/image/WindowsPlayer.jpg)

You may have more ideas and may do similar workflows. But in combining the plugin functionality you can achieve great features in your solution. And because it is all one license, you don't need to add another plugin to your toolbox. It's all in our [MBS FileMaker Plugin](https://www.monkeybreadsoftware.com/filemaker/), over 12 years of work for our clients.

Please do not hesitate to contact us with your questions.
