U_SAVREND
Save a rendition scheme to a file
WSupported on Windows
|
USupported on Unix
|
VSupported on OpenVMS
|
NSupported in Synergy .NET
|
xcall U_SAVREND([filename], [scheme], [status][, flag])
Arguments
filename
(optional) The name of the rendition file. (a)
scheme
(optional) The rendition scheme name (a maximum of 30 characters). (a)
status
(optional) Returned with zero (0) if the save operation is successful, or a Synergy DBL error number if it is unsuccessful. (n)
flag
(optional) If true (non-zero), U_SAVREND prompts the user before replacing an existing scheme of the same name. If false, it is replaced without warning. (n)
Discussion
U_SAVREND saves a rendition scheme to a rendition file. It opens filename in U:I mode and closes it upon exit. If filename doesn’t exist, it is created.
If filename is not specified, UI Toolkit searches for the rendition file as follows:
- If the environment variable DTKRNDFIL is defined, the rendition filename is DTKRNDFIL’s value.
- If DTKRND is defined instead of DTKRNDFIL, the rendition file is opened as DTKRND:dtkrnd.ism.
- If neither environment variable is set, dtkrnd.ism is opened or created in the current directory.
If scheme is not specified or is blank, the currently loaded renditions are saved to the working rendition scheme (blank key).
See also
Customizing the look of your application
Examples
The following utility subroutine loads and saves personalized rendition schemes from a rendition file.
subroutine pers_rend a_scheme ,a a_rstflg ,n ;Restore flag: 1=restore, 0=save .include "WND:tools.def" .define RENDFILE ,"RND:persrnd" record error ,i4 proc if (a_rstflg) then xcall u_rstrend(RENDFILE, a_scheme, error) else xcall u_savrend(RENDFILE, a_scheme, error, TRUE) if (error) xcall proc_error xreturn endsubroutine