Function Entry: GETVAR
← Prev | ↑ Chapter | Next → | Index | Symbols
Function Entry: GETVAR
Name
getvar
Class
Host Interaction Function
Syntax
(getvar varname)
Arguments and Values
varname: system-variable name designator, usually a string
Autodesk documents varname as a string naming a system variable.
Description
Retrieves the value of an AutoCAD system variable.
The per-sysvar entries in §16 System Variables document every
varname recognized by AutoCAD 2026 or BricsCAD V25, with the
declared type, default, read-only flag, scope, vendor divergence,
and source URLs. The normative rules at the head of that chapter
(name case-insensitivity, integer clamping, unknown-name semantics,
read-only behaviour, angular-units convention) apply uniformly to
every getvar call.
Return Values
Integer, real, string, list, or nil.
Autodesk documents that nil is returned if varname is not a valid system variable.
Side Effects
None.
Affected By
- host drawing/session state
- selected environment profile
Availability
- AutoCAD 2026: documented (per Autodesk reference page).
- BricsCAD V26: presumed compatible (no contradicting page found).
- Status: AutoCAD documented; BricsCAD presumed-both pending Phase 4 verification.
Source Notes
- [getvar (AutoLISP)](https://help.autodesk.com/cloudhelp/2026/KOR/AutoCAD-LT-AutoLISP-Reference/files/GUID-9C56BEA8-D473-4305-9E17-BEF7630C334D.htm)
- [About System and Environment Variables (AutoLISP)](https://help.autodesk.com/cloudhelp/2026/JPN/AutoCAD-MAC-AutoLisp/files/GUID-529819FD-9E9C-4789-BA18-B981BA32DD23.htm)
- See §16
System Variablesfor the per-name catalogue and normative rules.
Compatibility
Supported on Windows, macOS, and Web in current Autodesk documentation.