Yesterday we got a call from a good client asking for a IPCSocket replacement in Xojo. The existing
IPCSocket class in Xojo didn't work for them when using a Windows service.
So we started yesterday evening with the development of our new
WindowsPipeMBS class. The class can work client or server side, so you can either create a pipe or connect to one. When the connection is made, we fire the Connected event and in case the pipe breaks, we fire the PipeBroken event. There you can close the pipe and create or connect a new pipe.
For a pipe you can define the name which is used to refer to the pipe. You define the buffer size for the input and output buffers. And when using applications running in different user accounts, we can allow other users to connect. This allows especially a service to be connected by a normal user application.
To send data, we got a Write method, which takes either MemoryBlock or String to send. When data arrives, the DataAvailable event is triggered. You can check the given parameters there or use the BytesAvailable property to know how much data is there. With Peek function, you can look at the data you need or use PeekAll at all the data in the incoming buffer. With Read or RealAll you can read the content of the buffer and remove it from there.
The pipe can be run in message mode. Default is to run in byte mode, which means you read and write just bytes. When using message mode, each call to Write creates a message. When you read on the other side, you get each message as one block. So in data available handler you get a call for each message with MessageBytesAvailable property showing the size. When you call ReadAll, you get just the content of message, even if more data is in the buffer. Once a message is read, you can read the next message. Message mode is great, when your payload is for example JSON data.
We hope you enjoy the new class and our customer is happy as they got the desired class in less than 24h.
The
WindowsPipeMBS class will be part of the MBS Xojo Plugins 19.5.
Six months till the
XOJO.CONNECT 2020 in Nashville, Tennessee, USA. You have a few days left for early bird pricing:
It will be held March 25-27, 2020 in Nashville, TN at the
Sheraton Music City Hotel.
Registration is currently $200 off full price till 15th Sep 2019 ($799 instead of $999). Please sign up early to get the best deal.
Check out our
conference highlights video if you want to see what it's like - or ask one of the many attendees from the forum!
Looking for a conference this year? Join the
European Xojo Conference 2019 in Cologne, October 24-25th.
PS: If you fly from Europe, it can be cheaper for the tickets to add a few extra days and stop for example in New York compared to flying directly.
Only one month left before our conference & training for Xojo starts.
Your chance to meet Xojo developers in Europe without traveling to USA.
Five reasons why you should attend a conference:
- Learn something new.
With API 2.0, new Web Framework and Android coming soon and recent changes for MacOS Catalina, take the chance to learn information from first hand and ask your questions. - Networking with peers
Find new contacts, people that may help you with problems. Try to ask everyone what they do and build a list of experts. Meet the people from the Xojo forum and thank them for their help in the past. - Encounter new vendors and suppliers
Meet developers from plugins, components, training and other services. Use their services to provide greater values to your clients. - Position yourself as an expert
Let others know what you know and can do, so they can hire your services. Build a reputation as a valuable member of the community. - Have fun!
Leave your office and have a great time with other developers. Use your visit to Cologne for some sight seeing.
Monkeybread Software is pleased to announce the
European MBS Xojo Conference in metropolitan Cologne, Germany. We meet in the lovely Dorint Hotel in the center of Cologne. The hotel is in the city center and in walking distance to the main station. Beside our two conference days we have accompanying social programme with our dinner event and optional two training days. For the evenings we have casual get-together in the hotel bar or beer garden.
We have over 60 attendees signed up from 15 countries:
🇩🇪, 🇬🇧, 🇳🇱, 🇫🇷, 🇨🇭, 🇺🇸, 🇬🇷, 🇸🇮, 🇦🇹, 🇮🇹, 🇺🇦, 🇪🇸, 🇯🇴, 🇧🇪, & 🇨🇦.
The schedule:
Oct 23rd: Xojo Training in English
Oct 24th: Conference, first day with dinner event
Oct 25th: Conference, second day
Oct 26th: Xojo Training in German
Registration is open. Attending the conference costs regularly 699 Euro plus VAT, including food and beverage in the Dorint Hotel as well as an accompanying social program.
Get a
599 Euro ticket when signing up before 30th September 2019.
Sessions are to be held in English. Our conference is conceived as a networking event for the Xojo community. The conference is an ideal opportunity for sharing your thoughts and your own development experience with fellow users and developers.
See also
conference website,
Things to do in Cologne beside our conference and
European Xojo Conference FAQ.
We still build plugins for REALbasic and Real Studio as some customers still need them. While 99% use Xojo, there is a small part of our customers still using older versions.
We plan to update our plugins this year with 19.5 version to make a really stable version of our plugins with 32-bit support for Real Studio (and REALbasic).
Not sure if we can continue with building Real Studio plugins in 2020 (Mac 32-bit), so we want to have a good (possibly) last version.
So please let us know any problem / bug you like to get fixed.
Please contact us, so you are on the list of Real Studio plugins here and also make sure your license is updated to cover November 2019, so you can use version 19.5 of our plugins.
On my next visit to Zurich, I'd love to make another Xojo developer meeting:
Wer hat Interesse an einem Xojo Entwicklertreffen im November in Zürich?
Einfach gemütlich zusammen sitzen und über Xojo schnacken.
Gerne zeige ich auch neue Pluginfunktionen oder helfe bei Problemen mit Xojo Projekten. Einfach Computer mitbringen und was zeigen.
Umfrage für Terminfindung:
Umfrage Zürich
Wer Interesse hat an einem Termin mit mir für Softwareentwicklung, Schulungen, Entwicklungshilfe, Plugin Empfehlungen, assistierte Fehlersuche, Code-Review und IT-Beratung, der darf sich gerne melden für eine baldige Terminfindung.
We got a new example to show how to put icons on a MapView control in Xojo:
As you see, we use the Xojo icon to mark all the XDC cities on the map including the next XDC location in Nashville.
If you are interested in a Xojo conference, check the next ones in
Cologne and
Nashville.
To show icons, we add
MKPointAnnotationMBS objects to the map and then in viewForAnnotation event, we return a new
MKAnnotationViewMBS object and assign the image property to set the image to show. If you use a
MKPinAnnotationViewMBS object, then only pins are shown and the image is ignored.
The example will be included in next prerelease, but you can have a copy if needed. Just contact us.
Nickenich, Germany - (September 17th, 2019) -- MonkeyBread Software today is pleased to announce
MBS Xojo Plugins 19.4 for macOS, Linux and Windows, the latest update to their product that is easily the most powerful plugin collection currently available for Xojo.
MBS Xojo Plugins have been updated and now includes over 2600 classes and 65,000 documented features, and the versatile plugins have gained more new functions:
With this version we update the plugin to work with Xojo 2019r2. A few changes where required due to API changes in Xojo. Please update plugins if you plan to use Xojo 2019r2.
MacOS 10.15 Catalina is coming soon and we prepare for it. We notarize the uploads to avoid warning dialogs and updated a couple of functions to use newer APIs, so they work for the new MacOS version.
ChartDirector got an update to handle fonts on the new MacOS version better. We added a new
NSColorSamplerMBS class to ask the user to pick a color from screen without needing permissions to take screenshots.
For MacOS we added a new
CopyFileMBS class. It provides the low level APIs used on MacOS to copy files with various options, recursive directory handling and handling of extended attributes. We upgraded our
CVPixelBufferMBS class with additional methods to create pixel buffers from data in memoryblocks and to create
CIImageMBS for it.
The
Vision framework on MacOS provides functions to detect faces, face landmarks, recognize text, barcodes, humans and animals. We added over 50 classes related to this framework to cover all the features for use in Xojo.
In our
Barcode plugin, we now support more Barcode types including the Ultra type. For detection of barcodes, we have new classes to search on quadrants of pages and detect multiple barcodes in an image. To debugging we provide pictures for bitmaps and luminance sources.
The
Java classes got an upgrade with using variants more. You can get/set a field via variant and we convert it to the data type of the property. You call methods and pass parameters as variant and we type conversion automatically. This greatly simplifies passing parameters and receiving results.
We added SSL connectivity for CubeSQL, more text encodings for
TextConverterMBS class,
LZ4MBS module for LZ4 compression, magnification methods to
WKWebViewControlMBS control, a hash function for
GMImageMBS class and
TagLibFileRefMBS class got a new SetProperties method to change ID3v2 tags for audio files.
ICScannerBandDataMBS class now provides picture property,
SHA512MBS class got a HMAC function and
CipherMBS class now better reports errors via exceptions.
Finally we updated DynaPDF to version 4.0.30.91, CURL to 7.66.0, CubeSQL client to 5.8.3, Xcode to 10.3 and zint library to version 2.6.5.
See
release notes for a complete list of changes.
New in this prerelease of the 19.4 plugins:
- Updated DynaPDF to version 4.0.30.92.
- Improved RemoveHTMLTagsMBS to ignore greater than or smaller than characters in quoted text.
- Added YieldTicks shared property to FileListMBS class.
- Added TagLibFileRefMBS SetProperties, e.g. to change ID3v2 tags in MP3 files.
Download:
monkeybreadsoftware.com/xojo/download/plugin/Prerelease/.
Or ask us to be added to our shared Dropbox folder.
Depending on your needs, we can offer four different ways to save a picture in tiff (and other) formats.
NSImageMBS is a high level class for handling images on MacOS and it can save in various formats.
CGImageDestinationMBS offers a way to export in something like 20 formats on MacOS and iOS (public.jpeg, public.png, com.compuserve.gif, public.tiff, public.jpeg-2000, com.apple.atx, org.khronos.ktx, org.khronos.astc, public.heic, com.microsoft.ico, com.microsoft.bmp, com.apple.icns, com.adobe.photoshop-image, com.adobe.pdf, com.truevision.tga-image, com.ilm.openexr-image, public.pbm, public.pvr).
For cross platform projects, you can for example try
GMImageMBS class, which can write in over 100 formats. If you need tiff specific details, you may want to check our dedicated
TiffPictureMBS class, which allows you to control all details and lets you set individual header fields.
Dim p As Picture = LogoMBS(500)
// 1. NSImageMBS
Dim n As New NSImageMBS(p)
Dim tiff As String = n.TIFFRepresentation
Dim file1 As FolderItem = SpecialFolder.Desktop.Child("test1.tif")
Dim b As BinaryStream = BinaryStream.Create(file1)
b.Write tiff
b.Close
// 2. CGImageDestinationMBS
Dim image As CGImageMBS = CGImageMBS.CreateImage(p)
Dim file2 As FolderItem = SpecialFolder.Desktop.Child("test2.tif")
Dim dest As CGImageDestinationMBS = CGImageDestinationMBS.CreateWithFile(file2, "public.tiff", 1)
dest.AddImage(image, Nil)
If dest.Finalize Then
// MsgBox "Saved"
Else
MsgBox "Failed to save."
End If
// 3. GMImageMBS
Dim gmimage As New GMImageMBS(p)
Dim file3 As FolderItem = SpecialFolder.Desktop.Child("test3.tif")
gmimage.write(file3)
// 4. TiffPictureMBS
Dim t As New TiffPictureMBS
Dim file4 As FolderItem = SpecialFolder.Desktop.Child("test4.tif")
t.Pict = p
If t.Create(file4) Then
If t.WriteRGB Then
t.Close
// ok
Else
Break
End If
Else
Break
End If
Please do not hesitate to contact us with questions. And bring your projects with questions to the Xojo conferences to talk directly to us or Xojo engineers.
As you may know, we use TagLib, an open source library to read metadata from audio files, e.g. ID3 tags.
With our
TagLibFileRefMBS class you can read properties of an audio file including all the common values like artist, title, album or comment. We now got a setProperties method to update the properties and add/change/delete a few. Just pass in the dictionary with changes. Keys with nil values remove an entry and otherwise add or replace it:
Dim file As FolderItem = SpecialFolder.Desktop.Child("test.mp3")
Dim tag As New TagLibFileRefMBS(file)
Dim dic As Dictionary = tag.Properties
Break // inspect dictionary
dic.Value("ARTIST") = "John Doe"
dic.Value("ALBUM") = Nil // clear this one
tag.SetProperties(dic)
If tag.Save Then
MsgBox "OK"
Else
MsgBox "Failed to save"
End If
Currently TagLib supports both ID3v1 and ID3v2 for MP3 files, Ogg Vorbis comments and ID3 tags and Vorbis comments in FLAC, MPC, Speex, WavPack, TrueAudio, WAV, AIFF, MP4 and ASF files.
New in this prerelease of the 19.4 plugins:
- Added allowsMagnification and magnification properties as well as setMagnification method for WKWebViewControlMBS control.
- Added SSL connection modes for CubeSQL client in MBS Xojo SQL Plugin.
- Updated CubeSQL client to version 5.8.3.
- Added Picture and CGImage properties to ICScannerBandDataMBS class.
- Updated DynaPDF to version 4.0.30.91.
- Added NoSSL parameter for SetupAWS function in CURLSMBS class.
- Added Hash function for GMImageMBS class.
- Added MacROMBootVersion and MacBoardID functions to SystemInformationMBS class.
- Added setStartDate and setEndDate for EKEventMBS and CalEventMBS classes, so you can specify which time zone to use for converting between Date and NSDate.
- Added scale for alpha channel pictures for ScaleImageAndMaskMBS, ScaleMBS, ScalingMBS functions in Picture class.
- Updated CURL library to version 7.66.0.
- Added more properties to CURLSVersionMBS class.
- Added OptionSASLAuthZID property, kHTTP_VERSION_3 and kError_Auth_Error constants to CURLSMBS class.
Download:
monkeybreadsoftware.com/xojo/download/plugin/Prerelease/.
Or ask us to be added to our shared Dropbox folder.
If you use WIA classes in
MBS Xojo Win Plugin or
WIA functions in
MBS FileMaker Plugin, you may run into some Windows specific error codes. They all start with hex 8021 and below is a list of Windows Image Acquisition (WIA) error codes.
See also blog articles:
Error Code | Meaning | Hex Code | Decimal |
WIA_ERROR_BUSY | The device is busy. Close any apps that are using this device or wait for it to finish and then try again. | 80210006 | -2145320954 |
WIA_ERROR_COVER_OPEN | One or more of the device’s cover is open. | 80210016 | -2145320938 |
WIA_ERROR_DEVICE_COMMUNICATION | Communication with the WIA device failed. Make sure that the device is powered on and connected to the PC. If the problem persists, disconnect and reconnect the device. | 8021000A | -2145320950 |
WIA_ERROR_DEVICE_LOCKED | The device is locked. Close any apps that are using this device or wait for it to finish and then try again. | 8021000D | -2145320947 |
WIA_ERROR_EXCEPTION_IN_DRIVER | The device driver threw an exception. | 8021000E | -2145320946 |
WIA_ERROR_GENERAL_ERROR | An unknown error has occurred with the WIA device. | 80210001 | -2145320959 |
WIA_ERROR_INCORRECT_HARDWARE_ SETTING | There is an incorrect setting on the WIA device. | 8021000C | -2145320948 |
WIA_ERROR_INVALID_COMMAND | The device doesn't support this command. | 8021000B | -2145320949 |
WIA_ERROR_INVALID_DRIVER_RESPONSE | The response from the driver is invalid. | 8021000F | -2145320945 |
WIA_ERROR_ITEM_DELETED | The WIA device was deleted. It's no longer available. | 80210009 | -2145320951 |
WIA_ERROR_LAMP_OFF | The scanner's lamp is off. | 80210017 | -2145320937 |
WIA_ERROR_MAXIMUM_PRINTER_ ENDORSER_COUNTER | A scan job was interrupted because an Imprinter/Endorser item reached the maximum valid value for WIA_IPS_PRINTER_ENDORSER_COUNTER, and was reset to 0. This feature is available with Windows 8 and later versions of Windows. | 80210021 | -2145320927 |
WIA_ERROR_MULTI_FEED | A scan error occurred because of a multiple page feed condition. This feature is available with Windows 8 and later versions of Windows. | 80210020 | -2145320928 |
WIA_ERROR_OFFLINE | The device is offline. Make sure the device is powered on and connected to the PC. | 80210005 | -2145320955 |
WIA_ERROR_PAPER_EMPTY | There are no documents in the document feeder. | 80210003 | -2145320957 |
WIA_ERROR_PAPER_JAM | Paper is jammed in the scanner's document feeder. | 80210002 | -2145320958 |
WIA_ERROR_PAPER_PROBLEM | An unspecified problem occurred with the scanner's document feeder. | 80210004 | -2145320956 |
WIA_ERROR_WARMING_UP | The device is warming up. | 80210007 | -2145320953 |
WIA_ERROR_USER_INTERVENTION | There is a problem with the WIA device. Make sure that the device is turned on, online, and any cables are properly connected. | 80210008 | -2145320952 |
WIA_S_NO_DEVICE_AVAILABLE | No scanner device was found. Make sure the device is online, connected to the PC, and has the correct driver installed on the PC. | 80210015 | -2145320939 |
New in this prerelease of the 19.4 plugins:
- Changed SQL Plugin functions for ODBC on Mac to not complain about missing SQLBrowseConnect.
- Added LZ4MBS module.
- Improvements for next Xojo version.
- Added Name and Signature properties to JavaFieldMBS and JavaMethodMBS classes.
- Added CallStaticMethod for JavaClassMBS, CallMethod and CallNonvirtualMethod for JavaObjectMBS taking parameters as Variants.
- Added Field to JavaObjectMBS and StaticField to JavaClassMBS to get/set fields with variants.
- Added NewObject function to JavaClassMBS to pass parameters to constructor as variants.
- Added StringValue and Operator_Convert to JavaStringMBS class.
- Updated Graphics support in DynaPDFMBS class for next version of Xojo.
Download:
monkeybreadsoftware.com/xojo/download/plugin/Prerelease/.
Or ask us to be added to our shared Dropbox folder.
For next MBS Xojo Plugin, we add a LZ4 compression module called
LZ4MBS. LZ4 is a lossless compression algorithm with high performance.
We have Compress and Decompress methods for handling data in string and MemoryBlocks in Xojo:
Dim m As String = "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Lorem ipsum dolor site amat."
// make sure encoding is set
m = ConvertEncoding(m, encodings.UTF8)
// compress
Dim c As String = LZ4MBS.Compress(m)
// decompress
Dim d As String = LZ4MBS.Decompress(c)
// set encoding after decompressing
d = DefineEncoding(d, encodings.UTF8)
// and check
If d = m Then
MsgBox "Text match"
Else
MsgBox "Text doesn't match"
End If
You can download 19.4pr6 in the next days and try it. Please contact us if you have questions.
With MBS Plugin 19.4 we will include newer Java methods to make your live easier when working with Java classes in Xojo. Instead of passing arguments as memoryblock or checking which of the various methods to use, we simply use variants.
For fields, you can now use Field() or StaticField() methods to get or set the values. Values are passed as variant and we check which type is needed and do required conversions. All the normal data types should work fine this way like integers, floats, booleans or strings. You can pass/receive
JavaObjectMBS and subclasses of course. And for arrays please use the
JavaArrayMBS subclasses. As a convenience you can pass in Java string with a Xojo string and we create the java string for you.
For method calls, we got CallMethod, CallNonvirtualMethod and CallStaticMethod to call methods and pass arguments as array of variants. Same for NewObject method to create a new object by calling the constructor.
We add to
JavaObjectMBS class:
Field(TheField as
JavaFieldMBS) as Variant
CallMethod(MethodID as
JavaMethodMBS, args() as Variant) as Variant
CallNonvirtualMethod(TheClass as
JavaClassMBS, MethodID as
JavaMethodMBS, args() as Variant) as Variant
and to
JavaClassMBS class:
StaticField(TheField as
JavaFieldMBS) as Variant
NewObject(MethodID as
JavaMethodMBS, args() as Variant) as
JavaObjectMBS
CallStaticMethod(MethodID as
JavaMethodMBS, args() as Variant) as Variant
We hope you enjoy the new freedom to not build memoryblocks for parameters and let the plugin do the heavy work. Please don't hesitate to send us questions.
New in this prerelease of the 19.4 plugins:
- Fixed a problem with ActualTech ODBC drivers to connect from Mac to Microsoft SQL server.
- Fixed CDArrayMBS.percentile to return double.
- Fixed a bug in WordFileMBS class where it would not update the modified XML correctly for replace in header section.
- Updated zint library to version 2.6.5.
- Added barcode type Ultra.
- Fixed GMImageMBS functions to return picture to better work with GIF images.
- Fixed possible crash situation with SQL Plugin pinging server in background.
- Added systemIndigoColor and systemTealColor to NSColorMBS class.
- Updated ChartDirector to a newer version which loads fonts on MacOS Catalina.
Download:
monkeybreadsoftware.com/xojo/download/plugin/Prerelease/.
Or ask us to be added to our shared Dropbox folder.
The September/October (17.5) issue of
xDev Magazine is now available. Here's a quick preview of what's inside:
Numbers Please! Part 4 by Markus Winter
What is a number? And just how do you tell a program to detect a number? It's much more complicated than you'd think -- hope you like Regex formulas!
What's New in the MBS Plugins by Stefanie Juchmes
Based on Christian's talk at the Miami Xojo Conference, Stefanie covers many new aspects of the Monkeybread Plugins you might have missed.
Maps (Part 1) by Markus Winter
Would you like to include maps in your application? Be careful, as what used to be free now costs a fortune. Markus sets the stage for saving money by switching to Apple Maps.
Your First Web App -- Part 2 by Paul Budd
Paul continues to build his Web app, this time incorporating the functionality of adding records, searching, and using SQL prepared statements.
PLUS: Shared properties, power user features, standard operating procedures, Best of the Web, and more!
Xojo features a data type called currency. It is used for storing currency values and uses internally a 64bit value. As 4 digits are reserved for right of the dot, the 1.0 value is stored internally as 10000. When converting between double and integer, values are divided/multiplied by 10000.
There is a problem:
Double values are only precise for 15 digits, so having a big value like 123456789012345.1234 in a currency will not work correctly, as this can't be stored in a double. You get 123456789012345.1136. There are rounding issues.
But some of use need to work with huge numbers and functions like val() internally use double, so there are rounding issues with parsing.
For next plugin we'll add a function
CurrencyValueMBS to fix that. Our
CurrencyValueMBS function will return currency values parsed up to "+922337203685477.5807" just fine. If value is out of range, we raise an exception, so you can track down errors.
About 12 years ago we started the development of our DynaPDF Plugin.
After a year of development, the plugin was released to the public on 1st Sep 2007 with MBS Plugin 7.6pr1.
This plugin has been a big success for us and provides the PDF engine to thousands of Xojo applications around the world. Based on user feedback we got a lot of functions over the years like the raster engine, PDF/A conversion and ZUGFeRD support.
Please make sure you try the plugin, make it part of your toolbox and start to enjoy all the PDF features you can add to your application.
MBS Plugin supports generating over 80 barcode types, so we made a new graphics to show a few common barcodes:
Wether you need to make UPC or EAN in various versions, QR Code in normal or micro size, we cover them all.
Available with
Barcode functions in our
MBS FileMaker Plugin and in
BarcodeGeneratorMBS class in our
MBS Xojo Barcode Plugin.