Category Archives: Uncategorized

Wow… I can’t believe it!

That guy is still alive.
Been awfully quiet around here.

Sorry folks, quite busy, working hard, treadmill, you know the works…

Anyhow, I do have something new!

Remember the good old times when you could print a structure?
Well, I do.
Sadly that option has gone the way of the Dodo some versions ago.
Yes, I know, there are a few solutions out there. Some usable, some not, some an eyesore, some quite elegant.
So, well, you know me, had to roll my own!

And here we go:

AC_StructToPicture

I admit not the most imaginative of names but it does what’s on the box!
And is fully configurable at that!

Also, it does not use a single table/field and not even one process or interprocess variable!

In my quite humble opinion, it is a nice example of using the new interface techniques working through the Form command.

All you need is to download it (it’s V17R5 so beware!), launch it and point it to an XML dump of your favorite structure.
For those who do not find my interfaces intuitive:

You can save and load presets, that’s collections of settings you make, so you only have to select Comic Sans once and can then use it on all your pictures…
Import Structure reads an XML structure dump, save structure stores it wherever you want as JSON, so you do not need to reparse it. And Load Structure obviously loads a stored JSON structure

All changes you make to settings are displayed in a preview for a table you select from the listbox, make the change and you will see it right away.

There is a second page for settings relating to relations:

I am not going to explain all of that, play around and see what happens.

The stuff concerning relations can only be seen once you render the structure using the Draw structure button.

It then show a new window with your structure, you can export the picture from there

Ok, that’s it,
Have fun, play around with it, maybe learn from it and if you find errors (there certainly are) either keep them or send me a message.

Usual disclaimer: now warranty, no support, no nothing and its uncompiled.

So long folks

Oh…

The download…

https://nextcloud.spostel.com/index.php/s/wSWgtWq4Qb9ydY2

Made a small correction that would lead to funny results on systems that use the “.” as decimal separator….
Thanks Cannon

To backup or not to backup?

UPDATED to HF1 on 2017-06-09 go to downloads

We have all been there and done that:

You will know the value of backup when you don’t have one

4D has given us a powerful backup system with a lot of features users of other systems envy us for.

What man do not realize, is that you can modify all parameters of a backup from you code, making changes on the fly and averting user errors.

Modifying the Backup.xml file allows you to set the schedule, files to be included, how to handle failures, basically everything that you can set in the backup settings panel of the database preferences.

Now I know that working with XML files is a bit tedious and not always very straightforward, also all the possible settings are a drag to keep track of.

Thus I have again come to the rescue and hereby publish my latest component:

AC_BackupTools

Continue reading

Fun with colors

It has become increasingly difficult to sell customers on the idea of amber text on a blackish screen, everybody expects brilliant, dazzling colors in Kodachrome…

Now 4D does work with colors and when defining colors you have the choice between using catchy names like light sable, dead otter or bami-goreng backwards and using a nomenclature that is a little bit like web colors, just replace the hash with 0x00 and you are set, easy as pie.

Now, out there, there are a lot of different color systems and (surprisingly) none is the one 4D uses!
There is RGB, CMYK, HSL, HSV and probably a few more I cannot be bothered with right now.

Now the interesting question:

How to convert between these systems and what about finding other information, like :

  • What’s the brightness of my color, useful for determining if text on it should be white or black
  • What does my color look like if its a tad darker
  • What do 50 shades of my color look like?

Well, do not despair, I obviously have the solution to the problem you never knew you had:

AC_ColorTools! Continue reading