I wrote a LISP routine called 'AngleInterceptPoint' which accepts a base-point (as an argument) and prompts the user for a specified angle and a selected line or pline segment. It then calculates the intercept of the selected line and the base-point through the specified angle. (I use this routine in other LISP programs.)
I recently wrote a second LISP routine called '#IPL' (with no arguments) which calls up 'AngleInterceptPoint' and supplies (getvar "LASTPOINT") as the base-point argument. I want to use #IPL to create a transparent command using vlax-add-cmd. My acaddoc.lsp file loads IPL.lsp which contains the following code:
(defun #IPL ( / ) (AngleInterceptPoint (getvar "LASTPOINT")))
(vlax-add-cmd "IPL" '#IPL "IPL" ACRX_CMD_TRANSPARENT)
(AngleInterceptPoint pt) works fine and (#IPL) works fine but 'IPL' returns "error: Visual LISP command document mismatch".
The Autodesk Knowledge Network article on vlax-add-cmd talks about recommending using a separate VLX namespace to load these functions but I'm not familiar with VLX namespace concepts beyond vl-bb-ref & vl-bb-set.
As always, any help is greatly appreciated.