« MBS @ FMTraining.TV -… | Home | New shortcut to move … »

MBS FileMaker Plugin 12.4

In this article we want to introduce you the new functions from the MBS FileMaker Plugin in version 12.4.

MongoDB

In the last release we already introduced our new component MongoDB which allows you to read and write data in MongoDB using FileMaker. Please have a look at the video MongoDB and MBS - A look under the hood which describes the functionality in more detail. In this release we have added a few new functionalities that should make your work with MongoDB even easier. With the functions MongoDB.CloseCollection and MongoDB.CloseDatabase you explicitly close a database or a collection. Normally you don't need to use these functions because when you open a new database/collection the previously used one will be closed automatically. However, there are cases where these functions are useful. The MongoDB.Rename function is one that some of you may have been waiting for, because you can rename an existing collection and database. With the MongoDB.InsertMany function we can add multiple documents to a collection at the same time. To do this, we specify a JSON array with the information in the parameters. Result sets in a search over a MongoDB database can be stepped through with a cursor. We also have some new functions for the cursor. The function MongoDB.CursorErrorDocument checks if an error occurred while integrating the cursor. If an error occurred server-side, the result is set to the server's reply document with the information about the error. The MongoDB.FindIndexes function fetches a cursor containing documents, each corresponding to an index on this collection. Some MongoDB commands return a "cursor" document. With the function MongoDB.NewCursorFromCommandReply you create a cursor object from the response of such a command.

CURL

We have some new features in the CURL section. The CURL.Options function gives you a JSON for a given CURL connection, containing all CURL options and their current set values. Matching to this we have also added some new options that we can set. The function CURL.SetOptionMaxLifeTimeConnection sets the maximum lifetime allowed for reusing a connection. Here we start measuring from the creation of the connection. This is specified in the function parameters in seconds. If we set the value to 0 then the connection cannot be reused. With the function CURL.SetOptionMimeOptions we set the MIME flags. CURL.SetOptionProtocolsString sets which protocols can be used for a connection. We have the following protocols to choose from: DICT, FILE, FTP, FTPS, GOPHER, GOPHERS, HTTP, HTTPS, IMAP, IMAPS, LDAP, LDAPS, POP3, POP3S, RTMP, RTMPE, RTMPS, RTMPT, RTMPTE, RTMPTS, RTSP, SCP, SFTP, SMB, SMBS, SMTP, SMTPS, TELNET, TFTP. Several protocols can be allowed. To do this, specify a comma-separated list of these protocols. If you want to allow all protocols listed here, just use ALL. Additionally we have the CURL.SetOptionReditProtocolsString with which you can define if a connection that uses a protocol can be used again for transfer. Also the CURL.SetOptionSSHHostPublicKeySHA256 function is new. It sets the public key of a SSH connection with a SHA256 hash.

XML

We also have two new functions from the XML component. With the function XML.SetSaveNoEmptyTags we determine if empty tags should have end tags or it should be displayed in a shorter version. in Variant 1 we set an empty tag with an end tag look like this <a> </a> or Variant 2 as short form <a/>. By default we use the short form. If you want to change that enter 1 as value in the new function. Matching to this we have the XML.GetSaveNoEmptyTags that gives us the setting that is actually used.

DynaPDF

Also in this release we have a few innovations for DynaPDF for you. This time the innovations focus on images. With the function DynaPDF.SetRenderingIntent we can define how our solution should interpret colors in an image. For this we have the choices: AbsoluteColorimetric, Perceptual, RelativeColorimetric and Saturation. The new functions DynaPDF.GetImageFileCount and DynaPDF.GetImageContainerCount are similar in their functionality. Both functions indicate how many images a multi-page TIFF file contains. With DynaPDF.GetImageContainerCount this file may also come from a container.

As you probably know, DynaPDF has a license system that distinguishes between the licenses Starter, Lite, Pro and Enterprise. Depending on which license you use, you can use certain functions of DynaPDF in your solutions. With the new function DynaPDF.HavePro you can check if your scripts are executed with a Pro version. For example, you can specify that certain script parts are only executed when a Pro or Enterprise version is used.

List

In the List component we also add a new function. With the function List.MatchesSubString we get back entries of a list that contain a certain substring. We see that the substring Miss was searched for in the given list. We then get back a list that contains entries that contain the word Miss. The entry She is missed shows that the function is not case sensitive.

Matrix

Since some versions we have the possibility to work with matrices. We have a new function in this release, the Matrix.Rotate function. This function transposes the given matrix, that means the original rows become the columns and vice versa. This can be very useful for some calculations. If we apply the function two times in a series to a matrix we get the original matrix again, we can see this in the example.

Remote Control

In the RemoteControl component there is a new function RemoteControl.InsertText. The function sends a given text to active window/control. It may work from a script, but you can use our schedule functions to delay delivery by running the function after a delay.

DirectoryWatcher

Finally I would like to introduce you to a function for use under Windows. The DirectoryWatcher component is already available in the plugin since version 7.1. With it you can watch directories for changes on Windows. You can now query the total number of changes with the function DirectoryWatcher.TotalChangeCount. This is especially useful in the debugging process to see how many changes happened between two time stamps by comparing the counter before and after.

We hope you will also find some interesting new features. We wish you a lot of fun with MBS FileMaker Plugin Version 12.4. If you need a license or have any questions, please contact us.

Claris FileMaker Plugin
27 09 22 - 16:26

Start Chat