Code:
(setq TxtObj
(vla-AddMtext
(vlax-get
(vla-get-ActiveDocument (vlax-get-Acad-Object))
(if (equal (getvar "cvport") 1)
'PaperSpace
'ModelSpace
)
)
(if (= (vla-get-Alignment obj) 0)
(vla-get-InsertionPoint obj)
(vla-get-TextAlignmentPoint obj)
)
0 <- What is this zero for?
(if (= (vla-get-ObjectName obj) "AcDbText")
(vla-get-TextString obj)
(vla-get-TagString obj)
)
)
)
How and where would I set up the conditional statements. I suppose I would use and if statement to match the two alignment points up
would It look somehting like this:
Code:
(setq jp (vla-get-alignment txtObj)
);end of setq
(if (= jp acAlignmentMiddleLeft)
(setq na "ml")
(command "_.justifytext" Obj "" na)