MLSYSTEM.XXX Special Files

Also see Special files in Migrating from ML3 for limitations of previously defined special files.

MLSYSTEM.108: Get Current Date

Format:

Satz Formatiertes-Datums-Satz.
  Datum-TTMMJJJJ 8 n.
  Datum-JJJJMMTT 8 n.
  Jahr 4 n.
  Monat 2 n.
  Tag 2 n.
  Tageskennzahl 1 n.  /* 1 = Mon, 7 = Sun      */
  Tageszahl 5 n.      /* Days since 1990-01-01 */

Datei:
Heute "MLSYSTEM.108".

Lesen Heute Formatiertes-Datums-Satz.

Gets the current date, with emphasis on Y2K support.

MLSYSTEM.112: Store/Retrieve Date (YYYYMMDD)

Format:

Satz Datums-Satz.
  Jahr 4 n.
  Monat 2 n.
  Tag 2 n.

Datei:
Datumsspeicher "MLSYSTEM.112".

Lesen Datumsspeicher Datums-Satz.

Schreiben Datumsspeicher Datums-Satz.

Mirrors MLSYSTEM.102, but with Y2K support.

Write: store date in internal date buffer. Read: retrieve date from internal date buffer.

MLSYSTEM.113: Store/Retrieve Date (Days since 1990)

Format:

Satz Tageszahl-Satz.
  Tageszahl 5 n.      /* Days since 1990-01-01 */

Datei:
Datumsspeicher-Tageszahl "MLSYSTEM.113".

Lesen Datumsspeicher-Tageszahl Tageszahl-Satz.

Schreiben Datumsspeicher-Tageszahl Tageszahl-Satz.

Mirrors MLSYSTEM.103, but days are counted since 1990-01-01.

Write: store date in internal date buffer. Read: retrieve date from internal date buffer.

MLSYSTEM.118: Format Date

Format:

Satz Formatiertes-Datums-Satz.
  Datum-TTMMJJJJ 8 n.
  Datum-JJJJMMTT 8 n.
  Jahr 4 n.
  Monat 2 n.
  Tag 2 n.
  Tageskennzahl 1 n.  /* 1 = Mon, 7 = Sun      */
  Tageszahl 5 n.      /* Days since 1990-01-01 */

Datei:
Datumsspeicher-Formatiert "MLSYSTEM.118".

Lesen Datumsspeicher-Formatiert Formatiertes-Datums-Satz.

Reads date from internal date buffer and formats it in an MLSYSTEM.108 compatible way.

MLSYSTEM.213: Selection List

Format:

Satz Balken-Satz.
  B-Start 20 a.
  B-Minimum 20 a.
  B-Maximum 20 a.
  B-annehmen 1 a.
  B-Zeile    2 n .

The last field - here named B-Zeile - is not defined in the ML3 documentation, but has been seen in the wild. Clearly its presence is optional. As it is unclear what user applications expect, we define it here:

  • On user cancellation, the last field is set to zero.
  • On successful termination, it it set to the line number of the selected line. The first line is defined to be line 1.

MLSYSTEM.310: Set System User Id

Format:

Satz User-Id-Satz.
  User-Id 3 n.

Datei:
UserIdInfo "MLSYSTEM.310".

User-Id = 10.
Schreiben UserIdInfo User-Id-Satz.

Sets the value for the ${userid} replacement string in DB table names. See db.emulation.

MLSYSTEM.901: List&Label Add-On

Optional. MUST have a compiler license with List&Label-Add-On.

Format:

Satz LLCO.
  Report-TemplateName                  50 a.
  Report-Type                          10 a.
  Report-DefaultFormat                 30 a.
  Report-AllowedFormats               100 a.
  Report-ShowOptionsDialog              1 n.
  Report-ShowDesigner                   1 n.
  Report-TableName                     50 a.
  Report-ExportFilename                30 a.
  Report-ExportPath                    30 a.
  Report-ExportQuiet                    1 n.
  Report-OpenResultFile                 1 n.

Driver code:

Schreiben LL LLCO.
Aufrufen PrintModel.
Schreiben LL Headerdef.
Schreiben LL LLCO.
Schreiben LL Linedef1.
Schreiben LL Linedef2.
Schreiben LL LLCO.

Launches List&Label to print (or design) the specified report template.

The fields as specified by Headerdef have to be filled before writing to LL for the first time. Typically you would use these fields for the header. (More than one record definition can be specified.)

The callback model PrintModel will be called to update the data fields specified by Linedef1 and Linedef2 (more than one can be specified). PrintModel has to indicate that there are more lines by setting gefunden to 1.

MLSYSTEM.902: Open file dialog

Show an open or save file dialog. Updates gefunden based on if the user has chosen a file or not.

Format:

Satz Dialog-Data.
  FileDialog-Filter 100 a.
  FileDialog-Caption 255 a.
  FileDialog-Initial-Directory 255 a.
  FileDialog-Filename 255 a.

Driver code:

FileDialog-Filter = "txt files (*.txt)|*.txt|All files (*.*)|*.*".
Lesen FileDialog FileDialog-Data. /* open */
Schreiben FileDialog FileDialog-Data. /* save */

MLSYSTEM.903: Send E-Mail

Sends E-Mail using Outlook.

Format:

Satz E-Mail-Daten.
  E-Mail-An 100 a.
  E-Mail-Betreff 255 a.
  E-Mail-Anhang 255 a.
  E-Mail-Zeile 80 a.

Driver code:

Schreiben E-Mail E-Mail-Daten. /* init */
Schreiben E-Mail E-Mail-Daten. /* additional lines */
Lesen E-Mail E-Mail-Daten. /* send */

If E-Mail-Zeile is defined as type html, an HTML E-Mail will be created.

On success, gefunden will be set to 1, on an internal or Outlook error, gefunden will be set to 0.