.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Custom Variable

2 REPLIES 2
SOLVED
Reply
Message 1 of 3
WonkaPet
886 Views, 2 Replies

Custom Variable

Hi there,

 

I was just wondering if anyone had a solution to this problem.

Similar to AutoCAD's native OFFSET routine I'd like my routine to be able to "remember" the unit type and the unit value (ie ft / 5.0, m /  5.0). The OFFSET routine is able to remember the unit value using the OFFSETDIST system variable.

 

Is there anyway to store my own custom variables on a per drawing basis so that if a user opens another drawing I'd be able to display those values in my routine? I don't want to use the USERS1-5 variables if possible.

 

Thanks,

2 REPLIES 2
Message 2 of 3
_gile
in reply to: WonkaPet

Hi,

 

You can probably get some inspiration from these old but still relevant topics from Kean Walmsley's blog:

Per-document data in .NET applications - Part 1

Per-document data in .NET applications - Part 2



Gilles Chanteau
Programmation AutoCAD LISP/.NET
GileCAD
GitHub

Message 3 of 3
_gile
in reply to: WonkaPet

You also can register custom system variables.

You can see the Variable class in the developper's documentation and this example at TheSwamp.

 



Gilles Chanteau
Programmation AutoCAD LISP/.NET
GileCAD
GitHub

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Forma Design Contest


Autodesk Design & Make Report