same thing in command line twice?

same thing in command line twice?

Anonymous
Not applicable
453 Views
4 Replies
Message 1 of 5

same thing in command line twice?

Anonymous
Not applicable
hi,
i load vba routine thru lsp file which is loaded at startup.the syntax is

(defun c:ndoor ()
(command "-vbarun" "ndoor.dvb!ThisDrawing.ndoor"))

when i type ndoor in command line same thing is asked twice.in first line nil is written.

Command: nd -vbarun
Macro name: ndoor.dvb!ThisDrawing.ndoor
Select inner edge of wall: nil
Select inner edge of wall:

when i run this thru vb editor,it works fine.what is the problem?
thanx
0 Likes
454 Views
4 Replies
Replies (4)
Message 2 of 5

Anonymous
Not applicable
I think the solution is to add a vbcr before your prompt, like:

ThisDrawing.Utility.GetEntity obj, points, vbCr & "Select MultiLeader: "
0 Likes
Message 3 of 5

Anonymous
Not applicable
thanx allen,
problem still remains.i have many vba work and same problem comes to all. only first line is asked twice.and first has nil.may b thr is problem in vbarun syntax?
0 Likes
Message 4 of 5

Anonymous
Not applicable
Bhuta, problem is I think in Lisp and not VBA, a Lisp will print the final statement twice, once as you intended and the second time as the output of the program.

Finish your Lisp routine with a (princ) command and this should stop, i.e.

(defun c:ndoor ()
(command "-vbarun" "ndoor.dvb!ThisDrawing.ndoor"))
(princ)
)
0 Likes
Message 5 of 5

Anonymous
Not applicable
thanx tere...
i tried so.but still some prob.u r right prob is in lsp.so i shifted the q to lsp forum.thr is CMDECHO sysvar.i dont know it affects this or not?
regards
0 Likes