What’s new in 4D v17 R4

More preemptive

Preemptive processes on 4D Remote

With 4D v17 R4, your processes can be run preemptively on 4D Remote, this means taking full advantage of the power of multi-core computers. Splitting an operation into pieces and running it on all available cores, in parallel, to get your results faster.

 
 

Begin / end SQL in preemptive mode

With 4D v17 R4, Begin SQLEnd SQL, and the associated SQL statements used with an internal database are now preemptive-compliant.  Now you can start all your requests in parallel and increase the speed of your applications if these commands are used to do a lot of asynchronous activity.

 

 

Synchronize your processes

4D v17 R4 includes the new command,  New signal. You can use this command to – for example – delegate work to a cooperative process in order to use a non-preemptive command. The command creates a shared object and allows you to manage the progression of the current process with two new methods: trigger() and wait().

 

4D Write Pro

Convert your documents to .DOCX Format

Starting with 4D v17 R4, 4D Write Pro documents can be exported in .docx format. To do so, use the new wk docx constant with the existing WP EXPORT DOCUMENT command, or use the WP EXPORT VARIABLE command.

 

New Vertical ruler

4D v17 R4 introduces a new vertical ruler. It allows users to graphically manage vertical margins. And if your document contains headers or footers, the spaces between them and the body of your document can also be modified with the vertical ruler. The new Show vertical ruler property is available from the Property List, allowing you to enable the display of the ruler.

 

get coordinates in a 4D Write Pro document

With 4D v17 R4, you can get coordinates in a 4D Write Pro document. The WP Get position command returns more information regarding the current position of a range or an element reference using two new attributes: bounds and rangeHeight. The first attribute describes the rectangle surrounding a range according to its type (either “default type” (characters), “paragraph type”“table type” or “picture type”). It also has attributes of its own: top, bottom, left, and right. The second attribute describes the height of the object’s boundary rectangle.

support of virtual structures

With 4D v17 R4, table and field expressions inserted into 4D Write Pro documents support the virtual structure definition of the database. This is done with the SET TABLE TITLES(…;*)  and SET FIELD TITLES(…;*) commands. The formula editor also supports the virtual structure, and since 4D automatically sets the user interface based on the system settings, the formula editor will be displayed in the user’s language.

4D for ios – Preview

support of multi-CRITERIA search

In 4D v17 R4, 4D for iOS supports multi-criteria search. After selecting your list form template, drop multiple fields into the search area to activate multi-criteria search. When specifying multiple values for the same field, an OR operator is used behind the scenes. Keep in mind that this feature is activated by default in all 4D for iOS-generated templates, for custom templates you’ll need to modify your existing svg file and replace the search class from “droppable field optional” to “droppable field optional multi-criteria”.

 

RESTRICTed queries

A new concept is introduced with 4D v17 R4: Restricted queries. They allow you to filter data to be displayed in your mobile app without being limited to tables and fields. Now you have control over which records are sent. For this, a new Data section is available. You can easily filter data you want to visualize in your app depending on general filter queries or user information through the On Mobile App authentication database method.

 

Create a custom data formatter

4D for iOS already includes basic data formatters for dates, percentage, time, etc. With 4D v17 R4, you can create your own data formatters and use them directly from the Project Editor. Create a …/Resources/Mobile/formatters folder at the same level as your data file. Inside that folder, you have the possibility to create other folders to separate your formatters, for example, integerToString folder, integerToImage and so on. Inside your folders, a JSON file must be created where the properties such as the name and type of formatters are added.

 
 

4D Language

 

Send Mail

Starting with 4D v17 R4, a new way to create and send emails is available. The new functionality is easy to use – and also more powerful than the previous way using 4D Internet Commands. The new SMTP New transporter command allows you to configure a new SMTP connection. Creating and sending emails follows three steps: creating your SMTP transporter, creating a mail object, then sending the email. A mail object has multiple properties: from, cc, bc, to, sender,textBody, htmlBody, to name a few. In addition, an attachment can be added with the MAIL New attachment command. Once created, the mail object can be sent with the transporter.send() command.

 

New server administration commands

The 4D v17 R4 language completes the list of command that gives you the ability to create your own administration interfaces as dialogs on the server, client, or even as HTML pages for web access.

SEND MESSAGE TO REMOTE USER to send a message from the server to a remote user.

Get process activity to retrieve a list of user sessions.

DROP REMOTE USER to end a user session.

ABORT PROCESS BY ID to stop a specific process by using its unique process number.

Get process activity or Process properties to retrieve the unique process number.

REJECT NEW REMOTE CONNECTION to block new remote connections.

Get application info to tell if the connections have been accepted or refused.

SOAP REJECT NEW REQUESTS to block SOAP requests.

WEB Get server info to know if connections have been accepted or refused.

Refresh license to update a license.

 

4D view Pro

code a range in 4D VIEW PRO

With 4D v17 R4, you can create ranges via code. New commands are available to allow you define a range object to manipulate your cells: VP CellVP CellsVP ColumnVP RowVP All, VP Combine ranges, and VP Name. 

 

Name your ranges and formulas

A new concept is introduced with 4D v17 R4: named ranges and formulas. You can create two types of names with programming:

The first refers to a range of cells where you can apply a readable name via code to the cells you’re interested in with VP ADD RANGE NAME.

The second refers to a formula with VP ADD FORMULA NAME to replace calculations with readable names in your spreadsheets. It also creates a constant and makes the calculations in your spreadsheet easier.

 

Get and Set cell CONTENT

With 4D v17 R4, we’re providing you with a set of commands to fill your documents via programming: VP SET VALUE, VP SET BOOLEAN VALUE, VP SET DATE TIME VALUE, VP SET DATE VALUE, VP SET TIME VALUE, VP SET NUM VALUE, VP SET TEXT VALUE, VP SET FORMULA, VP SET FIELD, VP Get value, VP Get formula

 

Want to know more? Read all blog posts about 4D v17 R4