Over 1.110.000 registered users (EN+CZ).
AutoCAD tips, Inventor tips, Revit tips, Civil tips, Fusion tips.
Try the updated section Converters and online CAD tools,
new AutoCAD 2026 commands and environment variables.
Discussion forum
?CAD discussions, advices, exchange of experience
CAD discussion forum - ask any CAD-related questions here, share your CAD knowledge on AutoCAD, Inventor, Revit and other Autodesk software with your peers from all over the world. To start a new topic, choose an appropriate forum.
Please abide by the rules of this forum.
This is a peer-to-peer forum. The forum doesn't replace the official direct technical support provided by ARKANCE for its customers.
How to post questions: register or login, go to the specific forum and click the NEW TOPIC button.
|
Post Reply
|
| Author | |
kaleden
Newbie
Joined: 30.Sep.2008 Status: Offline Points: 1 |
Topic: Label Macro HelpPosted: 30.Sep.2008 at 00:41 |
|
So I'm working with AutoCAD LT and wanted to create a quick macro to label points on my drawing with the XY coordinates.
My macro SHOULD look like the following: ^C^C_id;\_setenv;mypoint;$M=$(getvar,lastpoint);_qleader;@;\;4;($M=$(rtos,$(index,0,$(getenv,mypoint)),2,1),$M=$(rtos,$(index,1,$(getenv,mypoint)),2,1));; The idea is as follows:
Perplexing. My current workaround involves splitting the macro into two parts: ^C^C_id;\_setenv;mypoint;$M=$(getvar,lastpoint); ^C^C_qleader;@;\;4;$M=$(rtos,$(index,0,$(getenv,mypoint)),2,1),$M=$(rtos,$(index,1,$(getenv,mypoint)),2,1));; This works, but I have to hit two shortcuts instead of one. Can anyone help me bring this macro into one? Am I the only one having issues with this macro? Thanks. |
|
![]() |
|
saverio
Newbie
Joined: 21.Oct.2008 Location: Italy Using: AutoCAD All versions Status: Offline Points: 5 |
Posted: 21.Oct.2008 at 02:18 |
|
All diesel macro are avaluated before executed.
So your getenv is evaluated BEFORE you clic. No way to solve this |
|
![]() |
|
Vladimir Michl
Moderator Group
Arkance Systems CZ Joined: 26.Jul.2007 Location: Czech Republic Using: Autodesk software Status: Offline Points: 2151 |
Posted: 21.Oct.2008 at 14:10 |
|
In fact there are ways to solve this - e.g. the LT Extension add-on uses a lot of such Diesel macros.
|
|
|
Vladimir Michl (moderator)
ARKANCE - https://arkance.world - Autodesk Platinum Partner |
|
![]() |
|
Sedlacek
Newbie
Joined: 21.Oct.2008 Status: Offline Points: 1 |
Posted: 21.Oct.2008 at 16:09 |
|
Use quotes.
^C^C_id;\_setenv;mypoint;$M=$(getvar,lastpoint);_qleader;@;\;4;"($M=$(rtos,$(index,0,$(getenv,mypoint)),2,1),$M=$(rtos,$(index,1,$(getenv,mypoint)),2,1))";; or ^C^C_id;\_setenv;mypoint;$M=$(getvar,lastpoint);_qleader;@;\;4;"$M=$(rtos,$(index,0,$(getenv,mypoint)),2,1),$M=$(rtos,$(index,1,$(getenv,mypoint)),2,1)";;^Z Edited by Sedlacek - 21.Oct.2008 at 16:35 |
|
![]() |
|
Post Reply
|
|
|
Tweet
|
| Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |
This page was generated in 0,133 seconds.
![CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor, Revit and other Autodesk products [www.cadforum.cz] CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor, Revit and other Autodesk products [www.cadforum.cz]](/common/arkance_186.png)


Label Macro Help
Topic Options


