HELP with wlax-invoke-method
Hello, i need help with following line(setq intersection(vlax-invoke-method vla_obj_first.IntersectWith(vla_obj_second, acExtendOtherEntity)))
i keep getting 'no function definition: VLA_OBJ_SECOND'...
of course i have converted two selected lines in vla objects; vla_obj_first and second, before calling that line...
thanx Try
(setq intersection (vlax-invoke-method vla_obj_first 'IntersectWith vla_obj_second acExtendOtherEntity))
Henrique that seems to work, but i added this
(setq intersection (vlax-safearray->list (vlax-invoke-method vla_obj_first 'IntersectWith vla_obj_second acExtendOtherEntity))) (princintersection)
to list that point, but i get 'bad argument type: safearrayp #'
how to list it? (princ (vlax-safearray->list (vlax-variant-value intersection)))
EDIT:
Tomislav,
using,
(setq intersection (vlax-invoke vla_obj_first 'IntersectWith vla_obj_second acExtendOtherEntity))
will return a normal point list or nil if no intersection found...
Henrique I FOUND IT
(setq intersection (vlax-safearray->list(vlax-variant-value (vlax-invoke-method vla_obj_first 'IntersectWith vla_obj_second acExtendOtherEntity)))) (princintersection)
THNX for help Henrique posted in same time as you so haven't saw your answer and it's great...i didn't know you can shorten it like that...many thanks You're welcome, Tomislav
Glad you got a solution.
Henrique
页:
[1]