; simple example:
(defun ALE_Block_Draw_Insert (NewLyr / LstEnt)
(if (> (atof (getvar "ACADVER")) 23.0)
(command "_CLASSICINSERT")
(progn (initdia 1) (command "_.INSERT"))
)
(setq LstEnt (entlast))
(command "_.CHPROP" LstEnt "" "_LAYER" NewLyr "")
(princ)
)
in this sample (entlast) refers to the last entity before the command.