Visual LISP, AutoLISP and General Customization

Visual LISP, AutoLISP and General Customization

Reply
*Rutledge, Phillip
Message 1 of 8 (89 Views)

Is it possible to add EED to a viewport entity

89 Views, 7 Replies
09-26-2002 05:41 AM
Hi there,
I tried to add extended entity data to a viewport but it didn't seem to
work. I noticed that ACAD already has EED attached. Can I not do this?
Thanks in advance for your help.
--
Phillip
*Jones, Bobby C.
Message 2 of 8 (89 Views)

Re: Is it possible to add EED to a viewport entity

09-26-2002 05:57 AM in reply to: *Rutledge, Phillip
You must use ActiveX automation to do this. Here are a couple of routines
that I developed for the purpose of adding xdata to vports.

http://code.acadx.com/visuallisp/041.htm
http://code.acadx.com/visuallisp/042.htm
--
Bobby C. Jones
www.AcadX.com
*per
Message 3 of 8 (89 Views)

Re:

09-26-2002 09:57 PM in reply to: *Rutledge, Phillip
Thanks Bobby,
I'll give them a go. Nice site you have there too. Keep up the good work.
--
Phillip


"Bobby C. Jones" wrote in message
news:EBBE2B8D3E7237245A69E3F5F7F727F9@in.WebX.maYIadrTaRb...
> You must use ActiveX automation to do this. Here are a couple of
routines
> that I developed for the purpose of adding xdata to vports.
>
> http://code.acadx.com/visuallisp/041.htm
> http://code.acadx.com/visuallisp/042.htm
> --
> Bobby C. Jones
> www.AcadX.com
>
>
*per
Message 4 of 8 (89 Views)

Re:

09-26-2002 11:15 PM in reply to: *Rutledge, Phillip
Hi Bobby,
Well this isn't going to be as easy as I had (thought) or hoped given my
VERY limited knowledge of activeX.
In your function ax:smileytongue:utXData, there are two arguments required (vlaObj &
XData).
1. What is the vlaObj? Is that the entity name?
2. XData - Don't I need to supply the APPID as well?
If you don't have the time to explain, I'll understand. I can see I need to
read-up more on the subject.
--
Phillip


"Bobby C. Jones" wrote in message
news:EBBE2B8D3E7237245A69E3F5F7F727F9@in.WebX.maYIadrTaRb...
> You must use ActiveX automation to do this. Here are a couple of
routines
> that I developed for the purpose of adding xdata to vports.
>
> http://code.acadx.com/visuallisp/041.htm
> http://code.acadx.com/visuallisp/042.htm
> --
> Bobby C. Jones
> www.AcadX.com
>
>
*per
Message 5 of 8 (89 Views)

Re:

09-26-2002 11:40 PM in reply to: *Rutledge, Phillip
Ok, I kinda' understand now about the vlaObj question I had. I see how to
convert an entity name to an ActiveX Object.
I'm not sure though why I don't need the APPID in PutXData... or do I?
--
Phillip

"per" wrote in message
news:C99EDB6017B41FE53ECA72B6E5DD501D@in.WebX.maYIadrTaRb...
> Hi Bobby,
> Well this isn't going to be as easy as I had (thought) or hoped given my
> VERY limited knowledge of activeX.
> In your function ax:smileytongue:utXData, there are two arguments required (vlaObj &
> XData).
> 1. What is the vlaObj? Is that the entity name?
> 2. XData - Don't I need to supply the APPID as well?
> If you don't have the time to explain, I'll understand. I can see I need
to
> read-up more on the subject.
> --
> Phillip
>
>
> "Bobby C. Jones" wrote in message
> news:EBBE2B8D3E7237245A69E3F5F7F727F9@in.WebX.maYIadrTaRb...
> > You must use ActiveX automation to do this. Here are a couple of
> routines
> > that I developed for the purpose of adding xdata to vports.
> >
> > http://code.acadx.com/visuallisp/041.htm
> > http://code.acadx.com/visuallisp/042.htm
> > --
> > Bobby C. Jones
> > www.AcadX.com
> >
> >
>
>
*Jones, Bobby C.
Message 6 of 8 (89 Views)

Re:

09-26-2002 11:47 PM in reply to: *Rutledge, Phillip
Hello Phillip,
Time is short these days, but I'll see if I can help shed some light. The
vlaObj argument expects an ActiveX object. Visual LISP provides you a
simple way to convert entity names into ActiveX objects with the
(vlax-ename->vla-object ...) function:

(setq vpEntity (car (entsel "Select a floating viewport: "))
vla:vpEntity (vlax-ename->vla-object vpEntity))

If you successfully select a floating viewport, vla:vpEntity will contain a
reference to your ActiveX viewport object. Feed it to ax:GetXdata and
observe what it returns:

(ax:GetXdata vla:vpEntity "ACAD")

Returns something similar to this:

((1001 . "ACAD")
(1000 . "MVIEW")
(1002 . "{")
(1070 . 16)
(1010 0.0 0.0 0.0)
(1010 0.0 0.0 1.0)
(1040 . 0.0)
(1040 . 1384.78)

(1002 . "{")
(1003 . "A-Area-Bdry")

(1003 . "S-Roof-Trus")
(1002 . "}")
(1002 . "}")
)

Notice that the 1001 key contains the AppID. This is how you will need to
structure your xdata list to feed to ax:smileytongue:utXdata. Be careful here! Unlike
the LISP method for storing xdata on an object, the ActiveX method will
automatically register your AppID if it's not already. A misspelled AppID
could cause you a lot of grief later.

I showed you one simple method of obtaining an ActiveX object. There are
others and the whole topic of Visual LISP's implementation of ActiveX is a
very broad topic. If you have other questions please ask. There are many
in this group whom are willing and more than able to help. Good luck.
--
Bobby C. Jones
www.AcadX.com
*per
Message 7 of 8 (89 Views)

Re:

09-27-2002 12:13 AM in reply to: *Rutledge, Phillip
The 1001 key... Ahhhh, the missing link... I see said the blind man. Thanks
so much Bobby.
Have a great weekend.
--
Phillip

"Bobby C. Jones" wrote in message
news:3369DA7E3B1236028563BA4D5C766691@in.WebX.maYIadrTaRb...
> Hello Phillip,
> Time is short these days, but I'll see if I can help shed some light. The
> vlaObj argument expects an ActiveX object. Visual LISP provides you a
> simple way to convert entity names into ActiveX objects with the
> (vlax-ename->vla-object ...) function:
>
> (setq vpEntity (car (entsel "Select a floating viewport: "))
> vla:vpEntity (vlax-ename->vla-object vpEntity))
>
> If you successfully select a floating viewport, vla:vpEntity will contain
a
> reference to your ActiveX viewport object. Feed it to ax:GetXdata and
> observe what it returns:
>
> (ax:GetXdata vla:vpEntity "ACAD")
>
> Returns something similar to this:
>
> ((1001 . "ACAD")
> (1000 . "MVIEW")
> (1002 . "{")
> (1070 . 16)
> (1010 0.0 0.0 0.0)
> (1010 0.0 0.0 1.0)
> (1040 . 0.0)
> (1040 . 1384.78)
>
> (1002 . "{")
> (1003 . "A-Area-Bdry")
>
> (1003 . "S-Roof-Trus")
> (1002 . "}")
> (1002 . "}")
> )
>
> Notice that the 1001 key contains the AppID. This is how you will need to
> structure your xdata list to feed to ax:smileytongue:utXdata. Be careful here!
Unlike
> the LISP method for storing xdata on an object, the ActiveX method will
> automatically register your AppID if it's not already. A misspelled AppID
> could cause you a lot of grief later.
>
> I showed you one simple method of obtaining an ActiveX object. There are
> others and the whole topic of Visual LISP's implementation of ActiveX is a
> very broad topic. If you have other questions please ask. There are many
> in this group whom are willing and more than able to help. Good luck.
> --
> Bobby C. Jones
> www.AcadX.com
>
>
>
*Jones, Bobby C.
Message 8 of 8 (89 Views)

Re:

09-27-2002 12:29 AM in reply to: *Rutledge, Phillip
Thanks..you too.
--
Bobby C. Jones
www.AcadX.com

"per" wrote in message
news:4193F584E2155BB813F784FDC5A68596@in.WebX.maYIadrTaRb...
> The 1001 key... Ahhhh, the missing link... I see said the blind man.
Thanks
> so much Bobby.
> Have a great weekend.
> --
> Phillip
Need installation help?

Start with some of our most frequented solutions or visit the Installation and Licensing Forum to get help installing your software.