Jump to content
GopinadhGvs

How to Getvar from List Command Autolisp..?

Recommended Posts

GopinadhGvs

Hi All,

 

How to getvar from "list" command..?

 

When we type list, select a line then it will print the results like (length, from point, to point etc..) in a textscr..

 

when i tried to getvar "length", it is returning nill.

 

can any one help me in doing this...

Share this post


Link to post
Share on other sites
jonathann3891

getvar only gets autocad variables.

Share this post


Link to post
Share on other sites
GopinadhGvs

Hai jonathann3891,

 

Thanks for your reply,

 

I am using getvar "area" to get the "area" value, using area the area value is printing on the command line..

 

The problem that iam getting in "List" is, here the value is printing on "textscr"..

 

If it is printing on command line, i think i can use getvar to get the printed values..

Share this post


Link to post
Share on other sites
BIGAL

Some variables are saved like, lastpoint, same also with properties it will display some properties but not necessarily evey one you want.

 

Use VL lisp to get properties

 

(alert (strcat "Length is " (rtos (vla-get-length (vlax-ename->vla-object (car (entsel)))) 2 3)))

Share this post


Link to post
Share on other sites
neophoible
Hai jonathann3891,

 

Thanks for your reply,

 

I am using getvar "area" to get the "area" value, using area the area value is printing on the command line..

 

The problem that iam getting in "List" is, here the value is printing on "textscr"..

 

If it is printing on command line, i think i can use getvar to get the printed values..

Command line is really part of the textscreen. Though you can copy and paste from the textscreen, I don't know of a way to capture the info using AutoLISP. Note that, though the area is being printed to the textscreen, that is not where getvar is getting the value. If you gave a concrete example of what you are trying to do, you might get more specific help.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×