Visual LISP Function Reference Chart for AutoCAD 200020022004

Document Sample
Visual LISP Function Reference Chart for AutoCAD 200020022004 Powered By Docstoc
					Visual LISP Function Reference Chart for AutoCAD 2000/2002/2004                                                                                                                                                                              1/4
Complied by Dr. June-Hao Hou <junehao@gmail.com>, Institute of Architecture, National Chiao Tung University, Taiwan. Last updated on 8/12/2008.

Basic Functions                               (cond [(test result ...) ...] )                                            (vl-string->list string)                                     (textscr)
Arithmetic                                    (eq expr1 expr2)                                                           Function-Handling                                            (vports)
(+ [number number] …)                         (equal expr1 expr2 [fuzz] )                                                (apply function list)                                        User Input
(- [number number] …)                         (if testexpr thenexpr [elseexpr] )                                         (defun sym ([args] [/ variables]) expr ...)                  (entsel [msg])
(* [number number] …)                         (or [expr ...] )                                                           (defun-q sym ([args] [/ variables]) expr ...)                (getangle [pt] [msg])
(/ [number number] ...)                       (repeat int [expr ...] )                                                   (defun-q-list-ref 'function)                                 (getcorner pt [msg])
                                              (while testexpr [expr ...] )                                               (defun-q-list-set 'sym list)                                 (getdist [pt] [msg])
(~ int)
(1+ number)                                   Error-Handling                                                             (eval expr)                                                  (getfiled title default ext flags)
(1- number)                                   (alert string)                                                             (lambda arguments expr ...)                                  (getint [msg])
(abs number)                                  (*error* string)                                                           (progn [expr] ...)                                           (getkword [msg])
(atan num1 [num2] )                           (exit)                                                                     (trace function ...)                                         (getorient [pt] [msg])
(cos ang)                                     (quit)                                                                     (untrace function ...)                                       (getpoint [pt] [msg])
(exp number)                                  (vl-catch-all-apply 'function list)                                        Application-Handling                                         (getreal [msg])
(expt base power)                             (vl-catch-all-error-message error-obj)                                     (arx)                                                        (getstring [cr] [msg])
(fix number)                                  (vl-catch-all-error-p arg)                                                 (arxload application [onfailure])                            (initget [bits] [string])
(float number)                                Symbol-Handling                                                            (arxunload application [onfailure])                          (nentsel [msg])
(gcd int1 int2)                               (atom item)                                                                (autoarxload filename cmdlist)                               (nentselp [msg] [pt])
(log number)                                  (atoms-family format [symlist] )                                           (autoload filename cmdlist)                                  Geometric
(logand int int ...)                          (boundp sym)                                                               (initdia [diaglogflag] )                                     (angle pt1 pt2)
(logior int int ...)                          (not item)                                                                 (load filename [onfailure])                                  (distance pt1 pt2)
(lsh int numbers)                             (null item)                                                                (startapp appcmd file)                                       (inters pt1 pt2 pt3 pt4 [onseg])
(max number number ...)                       (numberp item)                                                             (vl-load-all filename)                                       (osnap pt mode)
(min number number ...)                       (quote expr)                                                               (vl-vbaload filename)                                        (polar pt angle dist)
(minusp number)                               (set sym expr)                                                             (vl-vbarun macroname)                                        (textbox elist)
(rem num1 num2 ...)                           (setq sym1 expr1 [sym2 expr2] ...)                                         (vlax-add-cmd global-name 'func-sym                          Conversion
(sin ang)                                     (type item)                                                                    [local-name cmd-flags])COM                               (angtof string [mode])
(sqrt number)                                 (vl-symbol-name symbol)                                                    Utility Functions                                            (angtos angle [mode [precision]])
(zerop number)                                (vl-symbol-value symbol)                                                   Query & Command                                              (ascii string)
String-Handling                               (vl-symbolp object)                                                        (acad_colordlg colornum [flag])                              (atof string)
(read [string] )                              List Manipulation                                                          (acad_helpdlg helpfile topic)                                (atoi string)
(strcase string [which] )                     (acad_strlsort list)                                                       (command [arguments] ...)                                    (chr integer)
(strcat string1 string2 ...)                  (append list ...)                                                          (getcfg cfgname)                                             (cvunit value from to)
(strlen [string] ...)                         (assoc item alist)                                                         (getcname cname)                                             (distof string [mode])
(substr string start [length] )               (car list)                                                                 (getenv "variable-name")                                     (itoa int)
(vl-prin1-to-string object)                   (cdr list)                                                                 (getvar varname)                                             (rtos number [mode [precision]])
(vl-princ-to-string object)                   (cons new-first-element list)                                              (help [helpfile [topic [command]]])                          (trans pt from to [disp])
(vl-string-elt string position)               (foreach name list [expr ...] )                                            (setcfg cfgname cfgval)                                      Device Access
(vl-string-left-trim char-set string)         (last list)                                                                (setenv "varname" "value")                                   (grread [track] [allkeys [curtype]])
(vl-string-mismatch str1 str2 [pos1 pos2 (length list)                                                                   (setfunhelp "c:fname" ["helpfile" ["topic"                   (tablet code [row1 row2 row3 direction])
    ignore-case-p] )                          (list [expr ...] )                                                             ["command"]]])                                           File-Handling
(vl-string-position char-code str [start-pos (listp item)                                                                (setvar varname value)                                       (close file-desc)
    [from-end-p]] )                           (mapcar function list1 ... listn)                                          (ver)                                                        (findfile filename)
(vl-string-right-trim char-set string)        (member expr list)                                                         (vl-cmdf [arguments] ...)                                    (open filename mode)
(vl-string-search pattern string [start-      (nth n list)                                                               (vlax-add-cmd global-name 'func-sym                          (read-char [file-desc])
    pos] )                                    (reverse list)                                                                 [local-name cmd-flags])COM
                                                                                                                                                                                      (read-line [file-desc])
(vl-string-subst new-str pattern str [start- (subst newitem olditem list)                                                (vlax-remove-cmd global-name)COM
                                                                                                                                                                                      (vl-directory-files [directory pattern
    pos] )                                    (vl-consp list-variable)                                                   Display Control                                                  directories])
(vl-string-translate source-set dest-set str) (vl-every predicate-func list [more-lists] ...)                            (graphscr)                                                   (vl-file-copy "source-filename" "dest-
(vl-string-trim char-set string)              (vl-list* object [more-objects] ...)                                       (grdraw from to color [highlight])                               filename" [append?])
(vl-string->list string)                      (vl-list->string char-codes-list)                                          (grtext [box text [highlight]])                              (vl-file-delete "filename")
(wcmatch string pattern)                      (vl-list-length list-or-cons-object)                                       (grvecs vlist [trans])                                       (vl-file-directory-p "filename")
Equality & Conditional                        (vl-member-if predicate-function list)                                     (menucmd string)                                             (vl-file-rename "old-filename" "new-
(= numstr [numstr] ...)                       (vl-member-if-not predicate-func list)                                     (menugroup groupname)                                            filename")
(/= numstr [numstr] ...)                      (vl-position symbol list)                                                  (prin1 [expr [file-desc]])                                   (vl-file-size "filename")
(< numstr [numstr] ...)                       (vl-remove element-to-remove list)                                         (princ [expr [file-desc]])                                   (vl-file-systime "filename")
(<= numstr [numstr] ...)                      (vl-remove-if predicate-func list)                                         (print [expr [file-desc]])                                   (vl-filename-base "filename")
(> numstr [numstr] ...)                       (vl-remove-if-not predicate-func list)                                     (prompt msg)                                                 (vl-filename-directory "filename")
(>= numstr [numstr] ...)                      (vl-some predicate-func list [more-lists] ...)                             (redraw [ename [mode]])                                      (vl-filename-extension "filename")
(and [expr ...] )                             (vl-sort list less?-func)                                                  (terpri)                                                     (vl-filename-mktemp ["pattern" "directory"
(Boole func int1 [int2 ...] )                 (vl-sort-i list less?-func)                                                (textpage)                                                       "extension"])

 This work is licensed under the Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License. To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/3.0/ or send a letter to Creative Commons, 171
                                                                                     Second Street, Suite 300, San Francisco, California, 94105, USA.
Visual LISP Function Reference Chart for AutoCAD 2000/2002/2004                                                                                                                                                                              2/4
Complied by Dr. June-Hao Hou <junehao@gmail.com>, Institute of Architecture, National Chiao Tung University, Taiwan. Last updated on 8/12/2008.
(write-char num [file-desc])                               (expand number)                                                                  :properties-prefix pprefix
                                                                                                                         Namespace Communication
(write-line string [file-desc])                            (gc)                                                                             :constants-prefix cprefix])
                                                                                                                         Functions
Selection Set, Object &                                    (mem)                                                                        (vlax-method-applicable-p obj method)
                                                                                          (vl-bb-ref 'variable)
Symbol Table Functions                         Reactor Functions COM                      (vl-bb-set 'variable value)
                                                                                                                                        (vlax-object-released-p obj)
                                               (vl-load-com)                                                                            (vlax-read-enabled-p obj)
Selection Set Manipulation                                                                (vl-load-all "filename")
                                               (vlr-acdb-reactor data callbacks)                                                        (vlax-release-object obj)
(ssadd [ename [ss]])                                                                      (vl-propagate 'variable)
                                               (vlr-add obj)                                                                            (vlax-typeinfo-available-p obj)
(ssdel ename ss)                                                                          Windows Registry Functions
                                               (vlr-added-p obj)                                                                        (vlax-write-enabled-p obj)
(ssget [mode] [pt1 [pt2]] [pt-list] [filter-                                              (vl-registry-delete reg-key [val-name])
    list])                                     (vlr-beep-reaction [args] )                                                              Curve Measurement
                                                                                          (vl-registry-descendents reg-key [val-
(ssgetfirst)                                   (vlr-command-reactor data callbacks)A02        names])                                   (vlax-curve-getArea curve-obj)
(sslength ss)                                  (vlr-current-reaction-name)                (vl-registry-read reg-key [val-name])         (vlax-curve-getDistAtParam curve-obj
(ssmemb ename ss)                              (vlr-data obj)                                                                               param)
                                                                                          (vl-registry-write reg-key [val-name val-
(ssname ss index)                              (vlr-data-set obj data)                        data])                                    (vlax-curve-getDistAtPoint curve-obj pt)
                                               (vlr-deepclone-reactor data callbacks)A02                                                (vlax-curve-getEndParam curve-obj)
(ssnamex ss index)                                                                        (vlax-product-key)COM
(sssetfirst gripset [pickset])                 (vlr-docmanager-reactor data                                                             (vlax-curve-getEndPoint curve-obj)
                                                   callbacks)A02                          Visual LISP Extensions to                     (vlax-curve-getParamAtDist curve-obj
Object (Entity)-Handling                                                                  AutoLISP COM
                                               (vlr-dwg-reactor data callbacks)A02                                                          param)
(entdel ename)                                                                            Collection Manipulation
                                               (vlr-dxf-reactor data callbacks)A02                                                      (vlax-curve-getParamAtPoint curve-obj
(entget ename [applist])                                                                                                                    pt)
                                               (vlr-editor-reactor data callbacks)        (vlax-for sym collection [expr1 [expr2 ...]])
(entlast)                                                                                                                               (vlax-curve-getPointAtDist curve-obj dist)
                                               (vlr-insert-reactor data callbacks)A02     (vlax-map-collection obj function)
(entmake [elist])                                                                                                                       (vlax-curve-getPointAtParam curve-obj
                                               (vlr-linker-reactor data callbacks)        Data Conversion
(entmakex [elist])                                                                                                                          param)
                                               (vlr-lisp-reactor data callbacks)A02       (vlax-3D-point list)
(entmod elist)                                                                                                                          (vlax-curve-getStartParam curve-obj)
                                               (vlr-miscellaneous-reactor data            (vlax-3D-point x y [z])
(entnext [ename])                                                                                                                       (vlax-curve-getStartPoint curve-obj)
                                                   callbacks)A02                          (vlax-ename->vla-object entname)
(entupd ename)
(handent handle)
                                               (vlr-mouse-reactor data callbacks)A02      (vlax-make-safearray type '(l-bound . u- (vlax-curve-isClosed curve-obj)
                                               (vlr-notification reactor)A02                  bound) ['(l-bound . u-bound) ...])A02     (vlax-curve-isPeriodic curve-obj)
(vlax-dump-object obj [T])COM                                                                                                           (vlax-curve-isPlanar curve-obj)
                                               (vlr-object-reactor owners data callbacks) (vlax-make-variant value type)
(vlax-erased-p obj)COM                                                                                                                  (vlax-curve-getClosestPointTo curve-obj
                                               (vlr-owner-add reactor owner)              (vlax-safearray-fill var 'element-value)
(vlax-get-acad-object)COM                                                                                                                   givenPt [extend])
                                               (vlr-owner-remove reactor owner)           (vlax-safearray-get-dim var)
(vlax-method-applicable-p obj                                                                                                           (vlax-curve-
                                               (vlr-owners reactor)                       (vlax-safearray-get-element var element)
    method)COM                                                                                                                              getClosestPointToProjection curve-
                                               (vlr-pers reactor)                         (vlax-safearray-get-l-bound var dim)
(vlax-object-released-p obj)COM                                                                                                             obj givenPt normal [extend])
                                               (vlr-pers-p reactor)                       (vlax-safearray-get-u-bound var dim)
(vlax-read-enabled-p obj)COM                                                                                                            (vlax-curve-getFirstDeriv curve-obj
                                               (vlr-pers-release reactor)                 (vlax-safearray-put-element var element
(vlax-release-object obj)COM                                                                                                                param)
                                               (vlr-reaction-names reactor-type)              value)
(vlax-typeinfo-available-p obj)  COM                                                                                                    (vlax-curve-getSecondDeriv curve-obj
                                               (vlr-reaction-set reactor event function)  (vlax-safearray-type var)
(vlax-write-enabled-p obj)COM                                                                                                               param)
                                               (vlr-reactions reactor)                    (vlax-safearray->list var)
Extended Data-Handling                                                                                                                  Dictionary
                                               (vlr-reactors reactor-type)                (vlax-tmatrix list)
(regapp application)                                                                                                                    (vlax-ldata-delete dict key)
                                               (vlr-remove reactor)                       (vlax-variant-change-type var type)
(xdroom ename)                                                                                                                          (vlax-ldata-get dict key [default-data])
                                               (vlr-remove-all reactor-type)              (vlax-variant-type var)
(xdsize lst)                                                                                                                            (vlax-ldata-list dict)
                                               (vlr-set-notification reactor 'range) A02  (vlax-variant-value var)
Symbol Table & Dictionary-Handling (vlr-sysvar-reactor data callbacks)A02                                                               (vlax-ldata-put dict key data)
                                                                                          (vlax-vla-object->ename obj)
(dictadd ename symbol newobj)                                                                                                           (vlax-ldata-test data)
                                               (vlr-toolbar-reactor data callbacks)   A02
                                                                                          Method & Property-Handling
(dictnext ename symbol [rewind])               (vlr-trace-reaction arguments)             (vlax-invoke-method obj method list)          Notes:
(dictremove ename symbol)                      (vlr-type reactor)                         (vlax-method-applicable-p obj method)         • To refresh (the display of) an object
(dictrename ename oldsym newsym)               (vlr-types)                                (vlax-get-property obj property)                  after updating its property, issue this
(dictsearch ename oldsym newsym)               (vlr-undo-reactor data callbacks)A02       (vlax-property-available-p obj prop [T])          command: (vla-update object)
(layoutlist)                                   (vlr-wblock-reactor data callbacks)A02     (vlax-put-property obj property arg)          • All ActiveX and VBA predefined
(namedobjdict)                                 (vlr-window-reactor data callbacks)A02     (vla-method object arg1 arg2 ...)                 constants can be used in VLISP
(setview view-desc [vport-id])                 (vlr-xref-reactor data callbacks)A02                                                         expressions. For example: (vla-put-
                                                                                          (vla-get-property object)
(snvalid symname)                              VLX Namespace Functions                                                                      color mycircle acRed). See ActiveX
                                                                                          (vla-put-property object new-value)
(tblnext table-name [rewind])                                                                                                               and VBA Reference and
                                               (vl-arx-import [function | application])   Object-Handling
(tblobjname table-name symbol)                                                                                                              Connectivity Automation Reference.
                                               (vl-doc-export 'function)                  (vlax-create-object "prog-id")
(tblsearch table-name symbol [setnext])
                                               (vl-doc-import ['func | application])      (vlax-dump-object obj [T])
(vlax-ldata-delete dict key)COM                                                                                                                      LEGENDS
                                               (vl-doc-ref symbol)                        (vlax-erased-p obj)
(vlax-ldata-get dict key [default-data])   COM
                                                                                                                                          ItemA02 New in ACAD 2002
                                               (vl-doc-set symbol value)                  (vlax-get-acad-object)
(vlax-ldata-list dict)COM                                                                                                                 ItemA04 New in ACAD 2004
                                               (vl-exit-with-error "msg")                 (vlax-get-object "prog-id")
(vlax-ldata-put dict key data) COM
                                                                                                                                          ItemCOM Requires (vl-load-com)
                                               (vl-exit-with-value value)                 (vlax-get-or-create-object "prog-id")
(vlax-ldata-test data)COM
                                               (vl-list-exported-functions ["appname"]) (vlax-import-type-library
Memory Management                              (vl-list-loaded-vlx)                           :tbl-filename filename
Functions                                      (vl-unload-vlx)                                [:methods-prefix mprefix
(alloc int)                                    (vl-vlx-loaded-p "appname")
 This work is licensed under the Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License. To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/3.0/ or send a letter to Creative Commons, 171
                                                                                     Second Street, Suite 300, San Francisco, California, 94105, USA.
Visual LISP Function Reference Chart for AutoCAD 2000/2002/2004                                                                                                                                                                                   3/4
Complied by Dr. June-Hao Hou <junehao@gmail.com>, Institute of Architecture, National Chiao Tung University, Taiwan. Last updated on 8/12/2008.
                                                                     1- Auto Write Lock                                     :vlr-copied1                                                       VLA-obj: the source database;
Reactor Events and Callback
                                                                                                                                                                                          6

                                                                     2- Not Locked                                                                                                             ID map.
Data                                                                 4- Shared Write                                        :vlr-erased                                                   Window reactor events
                                                                     8- Read
                                                                     10- Exclusive Write                                    :vlr-unerased
Reactor Types                                                                                                                                                                             :vlr-docFrameMovedOrResized1
                                                               DWG reactor events                                           :vlr-goodbye
:VLR-AcDb-Reactor                                                                                                                                                                         :vlr-mainFrameMovedOrResized1
                                                               :vlr-beginClose                                              :vlr-openedForModify
:VLR-DocManager-Reactor                                                                                                                                                                       Callback args: reactor obj, list of extra data.
                                                               :vlr-databaseConstructed                                     :vlr-modified                                                     Callback data:
:VLR-Command-Reactor
                                                               :vlr-databaseToBeDestroyed                                   :vlr-subObjModified2                                          1    integer: the HWND of the window;
    :VLR-DeepClone-Reactor                                                                                                                                                                     T/nil: whether the window has been moved or resized.
                                                               :vlr-beginDwgOpen1                                           :vlr-modifiedUndone
    :VLR-DWG-Reactor                                                                                                                                                                      XREF reactor events
    :VLR-DXF-Reactor                                           :vlr-endDwgOpen1                                             :vlr-modifiedXData
                                                                                                                            :vlr-unappended                                               :vlr-beginAttach1
    :VLR-Insert-Reactor                                        :vlr-dwgFileOpened1
                                                                                                                            :vlr-reappended                                               :vlr-otherAttach2
    :VLR-Miscelleneous-Reactor                                 :vlr-beginSave2
    :VLR-Mouse-Reactor                                                                                                      :vlr-objectClosed                                             :vlr-abortAttach3
                                                               :vlr-saveComplete3
    :VLR-SysVar-Reactor                                                                                                          Callback args: owner, reactor obj, list of extra data.   :vlr-endAttach4
                                                                    Callback args: reactor obj, list of extra data.
    :VLR-Toolbar-Reactor                                                                                                      Callback data:                                              :vlr-redirected5
                                                                 Callback data:
    :VLR-Undo-Reactor                                           1 string: file to open
                                                                                                                             1 ename: the object created by the copy operation.
                                                                                                                             2 ename: the sub-object that has been modified.
                                                                                                                                                                                          :vlr-comandeered6
    :VLR-Wblock-Reactor                                         2 string: default file name for save.
                                                                                                                                                                                          :vlr-beginRestore7
                                                                3 string: actual file name used for save.
                                                                                                                            SysVar reactor events
    :VLR-Widow-Reactor                                                                                                                                                                    :vlr-abortRestore8
    :VLR-XREF-Reactor                                          DXF reactor events                                           :vlr-sysVarWillChange1                                        :vlr-endRestore8
:VLR-Linker-Reactor                                            :vlr-beginDxfIn                                              :vlr-sysVarChanged2                                           :vlr-xrefSubcommandBindItem9
:VLR-Object-Reactor                                            :vlr-abortDxfIn                                                   Callback args: reactor obj, list of extra data.
                                                                                                                                                                                          :vlr-xrefSubcommandAttachItem10
AcDb (Database) reactor events                                 :vlr-dxfInComplete                                             Callback data:
                                                                                                                             1 string: the sysvar name.                                   :vlr-xrefSubcommandOverlayItem11
                                                               :vlr-beginDxfOut
:vlr-objectAppended                                                                                                          2 string: the sysvar name;
                                                                                                                                                                                          :vlr-xrefSubcommandDetachItem12
                                                               :vlr-abortDxfOut                                                T/nil: whether the changed was successful.
                                                                                                                                                                                          :vlr-xrefSubcommandPathItem13
:vlr-objectUnAppended
                                                               :vlr-dxfOutComplete                                          Toolbar reactor events
:vlr-objectReAppended                                                                                                                                                                     :vlr-xrefSubcommandReloadItem14
                                                                    Callback args: reactor obj, list of extra data.         :vlr-toolbarBitmapSizeWillChange1
:vlr-objectOpenedForModify                                                                                                                                                                :vlr-xrefSubcommandUnloadItem15
                                                               Insert reactor events                                        :vlr-toolbarBitmapSizeChanged1
:vlr-objectModified                                                                                                                                                                           Callback args: reactor obj, list of extra data.

:vlr-objectErased                                              :vlr-beginInsert1                                                 Callback args: reactor obj, list of extra data.
                                                                                                                                                                                            Callback data:
                                                                                                                                 Callback data:
:vlr-objectUnErased                                            :vlr-beginInsertM2                                            1    T/nil: whether the toolbar is set to large bitmaps.
                                                                                                                                                                                          1  VLA-obj: target drawing db;
                                                                                                                                                                                             string: filename of the xref;
                                                               :vlr-otherInsert3                                                                                                             VLA-obj: source drawing db.
  Callback args: reactor obj, AcDb obj.                                                                                     Undo reactor events                                           2 VLA-obj: target drawing db;

Command reactor events                                         :vlr-endInsert4
                                                                                                                            :vlr-undoSubcommandAuto1                                         VLA-obj: source drawing db.
                                                               :vlr-abortInsert4                                                                                                          3 VLA-obj: source drawing db (contains the objs being
:vlr-unknownCommand                                                                                                         :vlr-undoSubcommandControl2                                      attached).
                                                                    Callback args: reactor obj, list of extra data.
:vlr-commandWillStart                                                                                                       :vlr-undoSubcommandBegin3                                     4 VLA-obj: target drawing db.
                                                                 Callback data:                                                                                                           5 integer: obj ID for the redirected symbol table record
:vlr-commandEnded                                               1 VLA-obj: the db in which the block is being inserted;     :vlr-undoSubcommandEnd3                                          (STR) in the drawing XREFed to;
                                                                  string: the block to be inserted;
:vlr-commandCancelled                                             VLA-obj: the source db of the block.                      :vlr-undoSubcommandMark3                                         integer: object ID for the object in the xref drawing.
                                                                                                                                                                                          6 VLA-obj: target db;
:vlr-commandFailed                                              2 VLA-obj: the target db;
                                                                                                                            :vlr-undoSubcommandBack3                                         integer: object ID;
                                                                  matrix: the 3D transformation matrix;                                                                                      VLA-obj: source drawing db.
  Callback args: reactor obj, List of cmd strings.
                                                                  VLA-obj: the source db of the matrix.                     :vlr-undoSubcommandNumber4                                    7 VLA-obj: target drawing db;
DeepClone reactor events                                        3 VLA-obj: the target db;
                                                                                                                                 Callback args: reactor obj, list of extra data.             string: XREF block tbl record (BTR) name;
                                                                  VLA-obj: the source db of the block or matrix.                                                                             VLA-obj: source drawing db.
:vlr-beginDeepClone                                             4 VLA-obj: the target db.
                                                                                                                              Callback data:
                                                                                                                                                                                          8 VLA-obj: target drawing db.
                                                                                                                             1 integer: the activity (always 4);
:vlr-beginDeepCloneXlation1                                    Linker reactor events                                           symbol: the state of Auto mode. T if turned on.            9 integer: activity the BIND is carrying out. Values:

                                                                                                                                                                                             0- BIND subcmd invoked.
:vlr-abortDeepClone                                            :vlr-rxAppLoaded
                                                                                                                             2 integer: the activity (always 4);
                                                                                                                                                                                             2- xref with indicated obj ID is begin bound.
                                                                                                                               integer: selected Control option. Possible values:
:vlr-endDeepClone                                              :vlr-rxAppUnLoaded                                              0- NONE was selected                                          3- xref with indicated obj ID was successfully bound.
                                                                                                                               1- ONE was selected                                           4- BIND subcmd completed.
  Callback args: reactor obj, list of extra data.                                                                                                                                            5- BIND operation is about to terminated or fail.
                                                                    Callback args: reactor obj, list of ObjectARX program      2- ALL was selected
   Callback data:                                                    names.                                                  3 integer: always 0.                                            6- BIND operation has terminated or failed.
 1 integer: error status.                                                                                                                                                                    7- Sent for XDep block bound by XBind.
                                                               LISP reactor events                                           4 integer: the activity (always 0);
                                                                                                                                                                                             8- Sent for all other symbols: Layers, Linetypes,
                                                                                                                               integer: the number of steps being undone.
DocManager reactor events                                                                                                                                                                    TextStyles, and DimStyles.
                                                               :vlr-lispWillStart1                                          Wblock reactor events                                            integer: obj ID for the xref being bound, or 0 if not
:vlr-documentCreated1                                          :vlr-lispEnded                                                                                                                applicable.
:vlr-documentToBeDestroyed1                                                                                                 :vlr-wblockNotice1                                            10 integer: activity the ATTACH is carrying out. Possible

                                                               :vlr-lispCancelled                                                                                                            values are 0, 2-6, see above.
:vlr-documentLockModeWillChange3                                                                                            :vlr-beginWblockPt2                                              string: file being attached, or nil if not applicable.
                                                                    Callback args: reactor obj, list of extra data.
:vlr-documentLockModeChangeVetoed2                                  Callback data:
                                                                                                                            :vlr-beginWblockId3                                           11 integer: activity the OVERLAY is carrying out.

                                                                                                                                                                                             Possible values are 0, 2-6, see above.
:vlr-documentLockModeChanged3                                   1    string: the 1st line of the AutoLISP exp to eval.      :vlr-beginWblock4                                                string: file being overlaid, or nil if not applicable.

:vlr-documentBecameCurrent1                                    Miscellaneous reactor events                                 :vlr-otherWblock4                                             12 integer: activity the DETACH is carrying out. Possible

                                                                                                                                                                                             values are 0, 2-6, see above.
:vlr-documentToBeActivated1                                    :vlr-pickFirstModified                                       :vlr-abortWblock5                                                string: file being detached, or nil if not applicable.

:vlr-documentToBeDeactivated1                                  :vlr-layoutSwitched1                                         :vlr-endWblock5                                               13 integer: activity the OVERLAY is carrying out.

                                                                                                                                                                                             Possible values are 0, 2-6, see above.
  Callback args: reactor obj, list of extra data.                   Callback args: reactor obj, list of extra data.         :vlr-beginWblockObjects6                                         integer: obj ID of the xref being operated on, or 0 if not
                                                                                                                                                                                             applicable;
  Callback data:                                                    Callback data:                                               Callback args: reactor obj, list of extra data.             string: new path name of the xref, or nil if not
 1 VLA-obj: the affected doc obj.                               1    string: the layout switched to.                          Callback data:                                                 applicable.
 2 VLA-obj: the affected doc obj;

   string: global cmd string passed in. Prefixed with "#" if
                                                               Mouse reactor events                                          1 VLA-obj: db object from which the block will be            14 integer: activity the RELOAD is carrying out. Possible

                                                                                                                               created.                                                      values are 0, 2-6, see above.
   the callback is being made on behalf of an unlock           :vlr-beginDoubleClick1                                        2 VLA-obj: the target db;                                       integer: obj ID of the xref being reloaded, or 0 if not
   request.                                                                                                                    VLA-obj: the source db;                                       applicable.
 3 VLA-obj: the affected doc obj;                              :vlr-beginRightClick1                                           3D pt list: the base point in the target db, in WCS.       15 integer: activity the UNLOAD is carrying out. Possible
   integer: lock in effect;                                         Callback args: reactor obj, list of extra data.          3 VLA-obj: the target db;                                       values are 0, 2-6, see above.
   integer: lock mode after the lock is applied;                                                                               VLA-obj: the source db;                                       string: obj ID of the xref being unloaded, or 0 if not
   integer: strongest lock mode from all other exec                 Callback data:                                                                                                           applicable.
                                                                                                                               object ID of the block TableRecord being wblocked.
   contexts;                                                    1    3D pt list: the point clicked on, in WCS.               4 VLA-obj: the target database;
   string: global cmd string passed in. Prefixed with "#" if
   it is an unlock request.
                                                               Object events                                                   VLA-obj: the source database.
                                                                                                                             5 VLA-obj: the target database.
   Lock modes are:                                             :vlr-cancelled
 This work is licensed under the Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License. To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/3.0/ or send a letter to Creative Commons, 171
                                                                                     Second Street, Suite 300, San Francisco, California, 94105, USA.
Visual LISP Function Reference Chart for AutoCAD 2000/2002/2004                                                                                                                                                                              4/4
Complied by Dr. June-Hao Hou <junehao@gmail.com>, Institute of Architecture, National Chiao Tung University, Taiwan. Last updated on 8/12/2008.

Externally Defined                                         DWGNAME: drawing name                                         1-369 (excfept 5 and 105) Can be used
                                                           DWGPREFIX: folder where drawing is                               in any way.
Commands
                                                             located
(c:3dsin mode [multimat create] file)
                                                           EXPERT: expert mode
(c:3dsout sset omode div smoth weld file)
                                                           LUNITS, LUPREC: non-angle number
(align arg1 arg2)                                            unit style and precision. Values are:
(c:cal expression)                                           1- Scientific notation
(c:fog enabled [color [near-dist [far-dist                   2- Decimal
    [near-percent [far-percent]]]]])                         3- Engineering (ft & dec. in.)
(c:light mode [options])                                     4- Architectural (ft. & frac. in.)
(c:lsedit mode [options])                                    5- Fractions
(c:lslib mode [options])                                   OSMODE: object snap modes (bit-
(c:lsnew obj-type height position                            encoded integer)
    alignment)                                             _PKSER: package serial number
(c:matlib mode name [file])                                TDCREATE: date/time, in Julian day
(mirror3d arg1 arg2 ...)                                     format, when the drawing is created
                                                           TDINDWG: time in days that the
(c:render [filename | pt1 pt2])
                                                             drawing has been worked on
(c:renderupdate [RU-value])
                                                           TEXTSTYLE: current text style name
(c:replay filename type [xoff yoff xsize
                                                           UCSNAME: UCS name
    ysize])
                                                           UNITMODE: 0 (default): loose; 1:
(c:rmat mode options)
                                                             compact.
(rotate3d args ...)
(c:rpref mode option [setting])
                                                           Extended Data (XData)
(c:saveimg filename type [portion] [xoff
    yoff xsize ysize] [compression])                       Group Codes
(c:scene mode [options])                 1000 String. A string up to 255 bytes.
(c:setuv mode options)                   1001 Application name. A string up to
                                           31 bytes. It is the beginning of a new
(c:showmat arg)
                                           application extended data group.
(c:solprof args)
                                         1002 Control string. A string, either "{"
(c:stats [filename | nil])                 or "}".
                                         1003 Layer name. A string.
VLAX Variant Types & Assoc. 1004 Binary data, up to 127 bytes. In
LISP Datatype                              ASCII DXF files, binary data is
0        vlax-vbEmpty nil                  represented as a string of
1        vlax-vbNull      :vlax-null       hexadecimal digits, two per binary
                                           byte.
2        vlax-vbInteger integer
                                         1005 Database handle. Refers to
3        vlax-vbLong
                                           another entity.
4        vlax-vbSingle
                                         1010, 1020, 1030 Three real values, in
5        vlax-vbDouble real
                                           the order X, Y, Z. Never altered.
8        vlax-vbString string
                                         1011, 1021, 1031 World space position.
9        vlax-vbObject VLA-object          A 3D point to be altered.
11       vlax-vbBoolean :vlax-true/false 1012, 1022, 1032 World space
8192+n vlax-vbArray vlax safearray         displacement. A 3D point to be
                                           altered.
System Variables                         1013, 1023, 1033 World direction. A 3D
ACADVER: ACAD version                      point to be altered.
ANGBASE: base angle orientation          1040 Real. A real value.
AUNITS, AUPREC: angle unit style and 1041 Distance. A real value that is
   precision. Values are:                  scaled along with the parent entity.
   0- Degrees                            1042 Scale factor. A real value that is
   1- Degrees/Minutes/Seconds              scale along with the parent.
   2- Grads                              1070 Integer. A 16-bit integer (signed or
   3- Radians                              unsigned).
   4- Surveyor's units                   1071 Long. A 32-bit integer.
CDATE: system date/time in readable        Example:
   format                                     (-3
                                              ("AppName1" (1000 . "HATCH") (1002 . "{")
CLAYER: current layer name                    (1070 . 16) (1000 . "LINE") (1040 . 1.0)
CMDACTIVE: whether a cmd is active?           (1040 . 0.0) (1002 . "}"))
                                              ("AppName2" (...))
CMDECHO: whether cmd echo is on?              ) ; end of xdata
CMDNAMES: cmd names currectly
   active                                XRecord Group Codes
CTAB: current (model/space layout) tab 100 Subclass marker (AcDbXrecord)
DATE: system date/time in comp format
 This work is licensed under the Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License. To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/3.0/ or send a letter to Creative Commons, 171
                                                                                     Second Street, Suite 300, San Francisco, California, 94105, USA.

				
DOCUMENT INFO
Shared By:
Categories:
Stats:
views:450
posted:2/12/2010
language:English
pages:4