SERIAL

Return the registration string of the current runtime

WTSupported in traditional Synergy on Windows

 

USupported on UNIX

 

xcall SERIAL(number)

Arguments

number

The variable that will be loaded with the registration string of the current Synergy runtime. (a)

Discussion

The SERIAL subroutine returns the registration string of the current Synergy runtime. (This is the unique registration string used on your License Agreement form, not your license number.)

A registration string is valid at 10 characters; however, to receive the fully qualified registration string, 12 characters are required. If number is longer than 12 characters, the data is loaded left‑justified over blanks. If number is shorter than 12 characters, the data is truncated.

Examples

The following subroutine displays an application time‑out message and instructs the user to call his or her developer for help.

subroutine timeout
    a_dev       ,a              ;Developer to call
    a_phone     ,a              ;Phone number to call
.include "DEF:workvar.def"      ;Include terminal channel number: TTCHN
literal msg
    msg         ,a*,    "Your system has expired. Call "
    at          ,a*,    " at "
    ser         ,a*,    ". Your registration string is: "
record
    rstr        ,a15            ;Formatted string ####-##-####-##
    reg         ,a12            ;Fully qualified registration string
proc
    xcall serial(reg)
    xcall s_bld(rstr,,"%a-%a-%a-%a",reg(1:4),reg(5:2),reg(7:4),reg(11:2))
    display(TTCHN, msg, a_dev, at, a_phone, ser, rstr)
    xcall cleanup               ;Clean up files, etc.
    xreturn
endsubroutine