Using lisp you can change variables, for a selected object, so the (command "DIMLUNIT" .... has no effect on what you have selected. Often with dims though need to reset more than 1 variable.
Use dumpit.lsp to look at properties you can change them.
For a ssget you need to loop through the selection set and use (ssname ssdim x) x is the selection set item number starts at 0.
I would also add a filter to your ssget (setq ssdim (ssget '((0 . "DIMENSION") )))
;;;===================================================================;
;;; DumpIt ;
;;;-------------------------------------------------------------------;
;;; Dump all methods and properties for selected objects ;
;;;===================================================================;
(defun C:Dumpit ( / ent)
(while (setq ent (entsel))
(vlax-Dump-Object
(vlax-Ename->Vla-Object (car ent))
)
)
(princ)
)
;(dumpallproperties (car (entsel)))
example of a change a dim (vla-put-arrowheadsize dimobj 5)
Do you know how to loop through a selection set ?