• Industries
  • Products
  • Buy
  • Services & Support
  • Communities
  • Discussion Groups

    AutoCAD 2013/2014 DWG Format

    Reply
    New Member
    Posts: 2
    Registered: ‎01-10-2013

    Limit file name length

    145 Views, 3 Replies
    01-10-2013 07:41 PM

    I have a drawing and I have a field calling up the path and file name.  Is their a way to limit the size of the path displayed?  For example, if my drawing is C:\users\name1\name2\name3\t4\new5.dwg, is their a way to only show ...\name3\t4\new5.dwg?

    Please use plain text.
    Valued Contributor
    Posts: 67
    Registered: ‎11-06-2008

    Re: Limit file name length

    01-11-2013 02:41 AM in reply to: Conveyor2

    Using DIESEL expression in you field will help point you in the right direction if you path names are all a consistent length

     

    for example,

     

    $(substr,%<\AcVar dwgprefix \f "%tc1">%,15)

     

    will display the path from the 15th character

     

    Also take a look at this link, one of the posts shows how to display a set number of characters from the end

     

    http://forums.augi.com/archive/index.php/t-68125.html

     

     

     

     

    Please use plain text.
    New Member
    Posts: 2
    Registered: ‎01-10-2013

    Re: Limit file name length

    01-12-2013 02:44 PM in reply to: Neil47

    Close.  But I can't to constant characters because the directory names will always be a diferent length.  I can say i just want everything from the third or fouth "\" forward.  Would that help?

    Please use plain text.
    Valued Contributor
    Posts: 67
    Registered: ‎11-06-2008

    Re: Limit file name length

    01-17-2013 06:54 AM in reply to: Conveyor2

    I don't think it will be possible with diesel

     

    I haven't much time at the moment to get too deep but there may be a solution here at this link

     

    http://forums.augi.com/showthread.php?140905-Folder-Name-into-Text-Field

     

    Please use plain text.