Using lookup tables and dynamic blocks, you can in some cases solve the formatting of automatic labels (fields) using leading zeros (and the "+" sign) - that is, formatting that preserves the number of decimal places before the decimal point/comma.
An example of such a block ("Lead0") can be found in the sample DWG drawing FmtBlk.dwg - see Block 22544 for download. This block displays the formatted value of the current rotation angle. Similarly, a distance parameter, number of elements, etc. can be used. To align the resulting text, it would be neccessary to move the text position, e.g. by using another lookup table.
The use of the dynamic Lead0 block is then illustrated in the video:
The video also uses the "trick" of automatic update of the text field value (so no manual regeneration of the drawing is required). The LISP reactor is used for this, which updates the fields after each block grip edit. However, it is not suitable for larger drawings (performance). To activate it, load the following LISP code (via .LSP file or by copying it to the command line or to ACADDOC.LSP):
Have we helped you? If you want to support the CAD Forum web service, consider buying one of our CAD applications, or our custom software development offerings, or donating via PayPal (see above).
You may also add a link to your web - like this "fan" link:
Featuring: Use Google Earth images in your AutoCAD projects with the Plex.Earth Tools
Please use these tips at your own risk. Arkance Systems is not responsible for possible problems that may occur as a result of using any of these tips.