If you want to insert a text in your drawing (e.g. to the title block) which contains a manipulated name of the current drawing file - e.g. the filename left-trimmed or right-trimmed at a number of characters, you can use a combination of Diesel expressions in an automatic text field (e.g. with the FIELD command).
Some examples:
Drawing file name, no path, from the 3rd character (paste as a Diesel expression to a Diesel-type field):
$(substr,$(getvar,DWGNAME),3,99)
Drawing file name, no path, no extension (4 characters), right-trimmed at another 3 characters (paste as a Diesel expression to a Diesel-type field):
Beginning of the drawing path (12 characters), ellipsis, first 8 characters of the drawing file name (paste as a Diesel expression to a Diesel-type field):
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: Publish interactive 3D PDF models from AutoCAD, Inventor or Revit with Share3D
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.