Using VLisp, I want to make a selection set that contains all the objects in the current workspace.
I do not know how to set one of the vlax-safearray-fill function arguments to exclude from the selection the objects on layers Freeze, Off and Lock.
Code:(setq ACDC (vla-get-activedocument (vlax-get-acad-object))) (vlax-for Obj (vla-get-layers ACDC) (if (or ;;Filter layers locked, frozen or off (eq (vla-get-freeze Obj) :vlax-true) (eq (vla-get-lock Obj) :vlax-true) (eq (vla-get-layeron Obj) :vlax-false) ) ;; (setq L_FILTER (append (list (vla-get-name Obj)) L_FILTER)) ;;Layer list (setq L_FILTER (append (list (list (vla-get-name Obj))) L_FILTER)) ;;Layer list of lists ) ) (setq SS_ALLO (vla-add (vla-get-selectionsets ACDC) (itoa (getvar "MILLISECS"))) F_CODE (vlax-make-safearray vlax-vbinteger (quote (0 . 1))) F_VALE (vlax-make-safearray vlax-vbvariant (cons 0 (1- (length L_FITER)))) ) (vlax-safearray-fill F_CODE (quote (8 410))) (vlax-safearray-fill F_VALE (list what_to_write_here? (getvar "CTAB"))) (vla-select SS_ALLO acSelectionSetAll nil nil F_CODE F_VALE)
Thank you.