Our Blog, FileMaker only, Xojo only, Archive (older)     Follow us on Twitter, Xing, LinkedIn or Facebook.

MBS Xojo Plugins, version 21.2pr8


New in this prerelease of the 21.2 plugins: Download: monkeybreadsoftware.com/xojo/download/plugin/Prerelease/ or from Dropbox.
Or ask us to be added to our shared Dropbox folder.

MBS FileMaker Plugin, version 11.2pr8


New in this prerelease of version 11.2 of the MBS FileMaker Plugin: Download at monkeybreadsoftware.com/filemaker/files/Prerelease/, in Dropbox folder or ask for being added to the dropbox shared folder.

Smooth scrolling list control with ContainerControls


Recently I implemented NSCollectionViewControlMBS control for Xojo to have a grid of items based on container controls. But a few days ago we had the need for having just a few containers to scroll on a window in Xojo. You may start to implement this in Xojo with a scrollbar and then move in the ValueChanged the containers up/down as needed. Quickly you may realize you need a wrapping container to clip the scrolling ones properly. But if you loop over containers and change their Top property to move them around, you may quickly see the scrolling not be smooth. We needed something better.

Since macOS comes with a NSScrollView class, I wanted to use that to push the job of scrolling and redrawing to the OS itself. So we have a Xojo managed inner and outer ContainerControl and slide our NSScrollViewMBS object between. We put all item containers on the inner ContainerControl, so Xojo may not know about the scrolling and just sees a big container in a smaller one. We configure the scroll view with a vertical scrollbar, some bezel around and a reasonable page scroll value.

When we try this setup, we can scroll smoothly and with mouse wheel support. We get the elastic scrolling with bouncing on the ends (can be disabled). This is fantastic and very smooth.

You may ask about Windows and Linux. Well, this may also be doable, but then with a regular Scrollbar itself. It may be tricky to get the redraw stuff smooth and avoid flicker. But well, I made an example for that, too. Tested on Windows and seems to work mostly with scrollbar controls. Since we only move the inner container up and down and let the container do clipping, it seems to work well with not much flicker.

And once I had that, I merged the two examples into one. Please try it soon as part of the examples coming with MBS Xojo Plugins in version 21.2pr7 or later. If you have feedback and improvements, feel free to send them back to us, so we can merge your changes into our example.

Improving our OCR functions for FileMaker Server


When we made our OCR functions back in September 2012, we designed them without reference numbers, so you can only have one current OCR job. Since FileMaker Pro always runs one script at a time (others are waiting), this is not a problem. But what happens on a server?

On a FileMaker server scripts may run in parallel. For a lot of customers this is no problem when occasionally a script runs, which may use OCR. But our active power users tend to do more and run scripts in parallel on multiple CPU cores. And there the mess starts with one script clearing the results of the other one since we hold the OCR state in a few global variables. You can mitigate this yourself with our Mutex functions, which allow you to have a script wait for another script to finish accessing a shared resource. While intended for our SharedMemory functions to synchronize memory access, it works fine to control access to OCR functions, too.

To fix the issue, we move to using per thread variables for our version 11.2 of the plugin. That means you can now have independent OCR setups on a FileMaker Server. Since FileMaker Server uses different threads to run scripts in parallel, you may have each script basically do the initialization, use OCR and do cleanup. If one script runs on first thread and initializes and later another script on second thread tries to access it, it may not see the initialization. You may detect this state by OCR.IsInitialized function. (more)

MBS Xojo Plugins, version 21.2pr7


New in this prerelease of the 21.2 plugins:
  • Added ContainerControl List example.
  • Updated PortAudio to version 19.7.0
  • Fixed problems in WindowsQOSMBS class.
  • Updated DNS functions for Windows.
  • Updated DLL linking for Windows to direct link functions requiring Windows 7.
  • Added newer constructor to NSKeyedArchiverMBS class to allow secure coding.
  • Added Archive and Unarchive methods to CKRecordMBS class.
  • Fixed issue with CloudKit events for CKFetchRecordZoneChangesOperationMBS and other classes.
  • Updated LibJPEG-Turbo to version 2.1.0.
  • Added explicit destructors for lots of CloudKit classes to explicit cleanup event handlers.
  • Added AVCaptureMetadataOutputMBS class for iOS.
  • Added constants to AVFoundationMBS class.
Download: monkeybreadsoftware.com/xojo/download/plugin/Prerelease/ or from Dropbox.
Or ask us to be added to our shared Dropbox folder.

MBS FileMaker Plugin, version 11.2pr7


New in this prerelease of version 11.2 of the MBS FileMaker Plugin:
  • Added SystemInfo.LinuxSystemInfo function.
  • Changed OCR functions to separate different threads on server better.
  • Updated DNS functions for Windows.
  • Updated DLL linking for Windows to direct link functions requiring Windows 7. Plugin works on Windows Server 2008r2 or newer, too.
  • Changed trace output for audit to show field name audited.
  • Fixed problem on Windows with AVRecorder.AddPreviewWithControl and AVRecorder.AddPreviewToWindow not using the FileMaker window, but a separate one.
  • Fixed problem with XML.ExtractText and XML.GetPathValue not seeing all text if there are XML nodes within a text block.
Download at monkeybreadsoftware.com/filemaker/files/Prerelease/, in Dropbox folder or ask for being added to the dropbox shared folder.

Bitsundso Download


For everyone watching regularly the Bitsundso Plus stream, we got a nice utility app (made in my spare time) to download the current episode as video:



You can download current version here: BitsundsoDownload.dmg

You need to specify the ID and password for the login. Than you specify where the ffmpeg command line tool is and where to store the video file. By default it will be put on desktop. Our tool just performs a login on Bitsundso website, gets the video stream URL, picks the 720p stream and downloads it by running ffmpeg. It shows you progress and opens video file on the end. Settings are saved for next run, so you can just run it every week, when you got the push for the new episode.
We have it in use for years now. With this update Apple Silicon is included and we made adjustments for Big Sur. Great for offline watching.

Have fun!

Linux System Info


For our MBS FileMaker Plugin we have the first linux only function: SystemInfo.LinuxSystemInfo.

This function provides some system information for Linux and returns it as a JSON block.

{
"UpTime": 708,
"Loads": [0.023873, 0.048828, 0.067382],
"TotalRAM": 4112195584,
"FreeRAM": 1589587968,
"SharedRAM": 1622016,
"BufferRAM": 20881408,
"TotalSwap": 4111462400,
"FreeSwap": 4111462400,
"Processes": 1010,
"TotalHigh": 0,
"FreeHigh": 0,
"MemoryUnit": 1,
"ConfiguredProcessors": 4,
"AvailableProcessors": 4,
"TotalPhysicalPages": 1003954,
"AvailablePhysicalPages": 388083
}

You may query such a block regularly and do your own decisions based on the numbers, e.g. only do something on the server if load counts are small. Or you may check how much memory is available on the computer. (more)

MBS Xojo Plugins, version 21.2pr6


New in this prerelease of the 21.2 plugins:
  • Updated DynaPDF to version 4.0.52.146.
  • Fixed a problem with TrueItem() function in FileListMBS not working right for alias files.
  • Fixed ShellMBS and WindowsProcessMBS classes for Windows to allow PowerShell.exe to run.
  • Added SkipParagraphs parameter for StyledText.RTFDataMBS to speed up conversion.
Download: monkeybreadsoftware.com/xojo/download/plugin/Prerelease/ or from Dropbox.
Or ask us to be added to our shared Dropbox folder.

MBS FileMaker Plugin, version 11.2pr6


New in this prerelease of version 11.2 of the MBS FileMaker Plugin: Download at monkeybreadsoftware.com/filemaker/files/Prerelease/, in Dropbox folder or ask for being added to the dropbox shared folder.

RFID reader for use with FileMaker


A client got a RFID reader, which can send a data packet through the local network, so you can receive them in FileMaker with out Socket functions.

The Ethernet Mifare® RFID Reader (ER750/ER755) has been tried by us and works.

You use the little configuration app on Windows to tell it which IP and port to connect to. Our normal TCP Socket example coming with our MBS FileMaker Plugin can do the receiving and show you the data. As text encoding use Hex since you get binary data. The first 4 characters are timestamp, package type and data length followed with up to 16 bytes of card UID. And since we need only that UID, we cut it from the data block with Middle($text, 13, 32). In hex all bytes take two characters. We get the UID as hex string and can store it in a database field for later comparison.

If you have trouble getting a connection, please make sure the Firewall lets the connection coming in. Beside a FileMaker Pro waiting for connection, you could of course use a little app or script on a computer to accept it and trigger whatever connection. For example a Xojo app using our MBS Xojo FMAPI Plugin could listen with a ServerSocket in Xojo, take the request and then use data API to create a record in FileMaker or perform a query to find the record for the UID. This may even run on a little Raspberry Pi computer and if the card is accepted put power on a PIN to trigger a door opener.

Please do not hesitate to contact us with your questions.

One month till dotfmp 2021


Did you sign up for FileMaker Conference dotfmp.berlin 2021?

This conference is organized by Egbert Friedrich and takes place from 3rd to 5th June 2021 in Berlin, Germany.
Since this year the meeting will be virtual again and in English, FileMaker developers from all over the world can join live from home.

Who
dotfmp is an effort of various leading European FileMaker Developers. It is meant to bring all kinds of higher level developers together to share knowledge, educate and challenge each other.
When
dotfmp starts at the 2nd June 2021 in the later afternoon with a relaxed "Beer and Sausages" in the virtual beer garden. The session days itself last from 3rd until 5th June with various socializing events in the evenings.
What
dotfmp is a 3 Day-Unconference, Meetup, Hangout or Barcamp. It is an informal and self-organized effort to meet on a personal base.
Where
This year it is virtual, so you can join from your home.
Why
We feel there are far too few possibilities to talk to, learn from, and hangout with fellow developers in a relaxed and informal environment. And we'd like to share work and get feedback from people chewing on similar challenges.


If you like to join the conference and present something, please register soon. A donation to help on the equipment cost is also welcome.
See you there!

xDev Magazine 19.3


The May/June (19.3) issue of xDev Magazine is now available. Here's a quick preview of what's inside:

More ARM by Marc Zeedar
Xojo's last update in 2020 was impressive, but its ARM support was missing a few elements. Thankfully, 2021R1 has fixed those flaws. Marc updates his benchmarks.

A Programming Black Hole by Markus Winter
Did you know that Xojo has a problem with basic math? Neither did Markus, until he fell down a programming black hole that led him to obscure 32-bit/64-bit oddities.

FileMaker-Like Checkboxes by Vince Du Beau
Vince wanted checkboxes in Xojo like he was used to having in Filemaker—so he wrote his own class to add them.

Holy Cryptography, Batman! by Eugene Dakin
If you're curious about cryptography, here's low-key introduction as Eugene starts a new series of articles beginning with the ancient Caesar Cipher.

Lost in the Woods by Markus Winter
Markus takes a break from his MapKit series to explore... mapping using Xojo's new MapLocation feature. How does it work?

Plus: Xojo 2021R1 new features, App Wrapper review, new PDF drawing, and much more!

The Xojo store is on sale!


Xojo Inc. just announced a sale for their web shop:

Get 20% off all Xojo licenses Today through Friday!

Plus take 20% everything in the Addons Store!

xojo.com/store


This sale includes a few MBS Plugin licenses in the add-on section of the Xojo store. If you like to order directly from us, we may offer the same discount for those new licenses.


MBS FileMaker Plugin, version 11.2pr5


New in this prerelease of version 11.2 of the MBS FileMaker Plugin:
  • Added SQL.ConvertDateTimeFromSQL and SQL.ConvertDateTimeToSQL functions.
  • Added Process.List function for macOS and Windows.
  • Changed search box for Script Workspace to consume double clicks to avoid resizing window.
  • Fixed Archive functions to do AES256 encryption on Windows.
  • Updated Linux 64-bit build machine to Ubuntu 18.04. Plugin still compatible to Ubuntu 16 and CentOS 7.7.
  • Changed Trace function to create log file, which is readable by other applications like a good text editor.
  • Fixed problem of Window functions on Windows not finding them.
  • Fixed WebView.SetFocus for iOS.
  • Changed FM.InsertRecordCSV and FM.InsertRecordTSV to recognize backslash escapes to have returns and tabs escaped in text.
Download at monkeybreadsoftware.com/filemaker/files/Prerelease/, in Dropbox folder or ask for being added to the dropbox shared folder.

MBS Xojo Plugins, version 21.2pr5


New in this prerelease of the 21.2 plugins: Download: monkeybreadsoftware.com/xojo/download/plugin/Prerelease/ or from Dropbox.
Or ask us to be added to our shared Dropbox folder.

MBS Plugin Quiz


Let us ask you a few questions and see how well you know our MBS FileMaker Plugin:

Which of the following functions is the oldest?

  • GMImage.Crop to crop an image
  • Schedule.StartScriptOnIdle to start a script when user takes a break
  • Process.List to list running applications on a Mac/PC.
  • Window.Hide to hide a window via plugin.
  • RegEx.Replace to make a replace with regular expression
  • (more)

    Customize your FileMaker solution


    When you deliver your FileMaker solution on macOS, you may customize the look of your application. This may include custom menus, toolbars and dock icons.

    Customize Menu

    You probably use a custom menu in FileMaker when you do a serious solution. Because you may not want to expose all the normal menu commands to your users, but reduce the feature set to what they actual need.

    Early in the start script you may want to call App.SetProcessName to set your solution name. This defines for example how the top left menu next to the Apple Menu is named on macOS.

    After you set the custom menu, you may further customize the menu and rename the content of the some menu entries. For example here we change the hide command to have a different name:

    MBS("Menubar.SetMenuCommandTitle"; "FileMaker Pro Advanced¶Hide FileMaker Pro Advanced"; "Hide MyApp")

    If you change the process name, you may need to change the menu path in the call. (more)

    Looking into WebUploadedFile class


    The Xojo Web framework contains a special class to hold information on an uploaded file, the WebUploadedFile class. Used by the WebFileUploader control this class provides you the information of the uploaded file. Let's take a deeper look:

    An uploaded file can either be backed in memory or backed by a temporary file. There is a threshold when files are put in memory or into a file and we don't know when exactly this happens. But there may be multiple reasons like memory usage.

    Consequentially if you query length, you are returned the length of the MemoryBlock or the temporary file. If you query Data, you get back the MemoryBlock or for a file backed one, the data is read and returned. This means the file has to fit in memory to not cause an exception. And it may cause a delay for the time to load the file. Sadly the trigger to loading data in memory may be when you stop in debugger and inspect the WebUploadedFile file. You then see file property and data property have content.

    The UploadComplete event is where you get the array of the uploaded files. Here you may process the data, e.g. take it pass it to Picture.FromData to read in a picture. If you store the WebUploadedFile object in a property of your web page, be aware that file backed uploaded files get their temp file deleted when the event finishes. So you have to take the data or query file property and copy the file. For performance doing a hard link into your own location may be the quickest way.

    The deletion of the temp file caused a few support calls in recent times where clients passed the folder items to DynaPDF or Zip/Archive functions to process them. Our functions had trouble to open the files, which is no wonder when being deleted.

    Looking on the temp folder, it looks like Xojo may push an upload into a temp file. Then later processes it and copies data into smaller temp files (or hold them in MemoryBlocks). Finally the temp file deleted when the request is processed.

    For the future, I'd wish they would delete the temp file in the destructor of the WebUploadedFile object, so we could keep it around a bit longer. A trick to do that may be to open the file and keep a BinaryStream for it around. On macOS and Linux you can delete an open file, so you can read it until the BinaryStream is closed and the file is really gone. On Windows you can't delete the file while it is open, so you may need to delete it yourself later.

    Linux Compiler Upgrade


    After we updated compilers for macOS and Windows recently, it may be time for Linux.

    To build all our plugins for 64-bit Linux (x86_64) we moved to Ubuntu 18.04 this week.

    It turns out that updating to a new version of a compiler is easy. You rebuild everything, check new warnings and handle some error messages for changes in C++ frameworks.

    But then we tried the plugin on CentOS 7.9 and this was a disappointment. Tons of missing libraries. Well, looks like the c and c++ libraries in CentOS are a few years older than the one in Ubuntu 18.04. Now either we fix the dependencies or we have to redo with CentOS to have a common base.

    It turns out you can track down dependency by dependency and use various compiler options to disable newer features and stay with older C++ version 11 instead of 14 or 17. I'd wish this would be easier, but I had to recompile dozens of times to see what each changes causes. e.g. for a normal standard C++ string, you have nine ways to construct them. But we now have to avoid the newer variants and then it works.

    On the end the plugin now loads on CentOS 7.8 and Ubuntu 18.4.
    If you use an older version of Linux 64-bit, we may be able to avoid another function for you, but not a dozen!

    Our first build of the plugins required glibc version 2.27, glibcxx 3.4.21 and cxxabi 1.3.9 as those are the ones coming with Ubuntu 18.04.
    The final builds are down to glibc version 2.17, glibcxx 3.4.18 and cxxabi 1.3, which makes it compatible with CentOS 7.9.
    Ubuntu 16 comes with CXXABI 1.3.9 and glibc 2.23, so we expect the plugins load on Ubuntu 16, too.
    We also tried a fresh installed CentOS 7.7 and it seems like things work there, too.

    Coming soon for pr5. If you like to try before that, please let us know.

    Older blog entries:

    2021-04-22 Xojo 2021r1.1 available
    2021-04-22 Drei Monate bis zur Deutschen FileMaker Konferenz 2021 in Malbun
    2021-04-21 Option Click for FileMaker Script Workspace
    2021-04-21 MBS Xojo Plugins, version 21.2pr4
    2021-04-21 MBS FileMaker Plugin, version 11.2pr4
    2021-04-20 ChartDirector 7 update
    2021-04-19 20000 members in Xojo forum
    2021-04-19 Query MBS Version from plugin in container
    2021-04-18 Big Sur and Xojo 2019r1.1
    2021-04-18 MBS Plugin versions shipped
    2021-04-18 GMail for emails with MBS Plugin
    2021-04-17 Hunting a memory leak in Xojo Web target
    2021-04-16 Linux 64-bit ARM support coming to Xojo
    2021-04-15 Lost messages
    2021-04-14 Spell Checking on Windows for Xojo
    2021-04-14 MBS Xojo Plugins, version 21.2pr3
    2021-04-14 MBS FileMaker Plugin, version 11.2pr3
    2021-04-09 Claris switches to Ubuntu for Linux servers
    2021-04-08 Thank you for the birthday cards
    2021-04-08 We are Claris Partner

    Archives

    May 2021
    Mar 2021
    Feb 2021
    Jan 2021
    Dec 2020
    Nov 2020
    Oct 2020
    Sep 2020
    Aug 2020
    Jul 2020
    Jun 2020
    May 2020
    Apr 2020
    Mar 2020
    Feb 2020
    Jan 2020
    Dec 2019
    Nov 2019
    Oct 2019
    Sep 2019
    Aug 2019
    Jul 2019
    Jun 2019
    May 2019
    Apr 2019
    Mar 2019
    Feb 2019
    Jan 2019
    Dec 2018
    Nov 2018
    Oct 2018
    Sep 2018
    Aug 2018
    Jul 2018
    Jun 2018
    May 2018
    Apr 2018
    Mar 2018
    Feb 2018
    Jan 2018
    Dec 2017
    Nov 2017
    Oct 2017
    Sep 2017
    Aug 2017
    Jul 2017
    Jun 2017
    May 2017
    Apr 2017
    Mar 2017
    Feb 2017
    Jan 2017
    Dec 2016
    Nov 2016
    Oct 2016
    Sep 2016
    Aug 2016
    Jul 2016
    Jun 2016
    May 2016
    Apr 2016
    Mar 2016
    Feb 2016
    Jan 2016
    Dec 2015
    Nov 2015
    Oct 2015
    Sep 2015
    Aug 2015
    Jul 2015
    Jun 2015
    May 2015
    Apr 2015
    Mar 2015
    Feb 2015
    Jan 2015
    Dec 2014
    Nov 2014
    Oct 2014
    Sep 2014
    Aug 2014
    Jul 2014
    Jun 2014
    May 2014
    Apr 2014
    Mar 2014
    Feb 2014
    Jan 2014
    Dec 2013
    Nov 2013
    Oct 2013
    Sep 2013
    Aug 2013
    Jul 2013
    Jun 2013
    May 2013
    Apr 2013
    Mar 2013
    Feb 2013
    Jan 2013
    Dec 2012
    Nov 2012
    Oct 2012
    Sep 2012
    Aug 2012
    Jul 2012
    Jun 2012
    May 2012
    Apr 2012
    Mar 2012
    Feb 2012
    Jan 2012
    Dec 2011
    Nov 2011
    Oct 2011
    Sep 2011
    Aug 2011
    Jul 2011
    Jun 2011
    May 2011
    Apr 2011
    Mar 2011
    Feb 2011
    Jan 2011
    Dec 2010
    Nov 2010
    Oct 2010
    Sep 2010
    Aug 2010
    Jul 2010
    Jun 2010
    May 2010
    Apr 2010
    Mar 2010
    Feb 2010
    Jan 2010
    Dec 2009
    Nov 2009
    Oct 2009
    Sep 2009
    Aug 2009
    Jul 2009
    Apr 2009
    Mar 2009
    Feb 2009
    Dec 2008
    Nov 2008
    Oct 2008
    Aug 2008
    May 2008
    Apr 2008
    Mar 2008
    Feb 2008
    XML: RSS Feed XML: Atom Feed