+ Reply to Thread
Results 1 to 8 of 8
  1. #1
    Forum Newbie
    Using
    AutoCAD 2000
    Join Date
    Nov 2010
    Posts
    6

    Default Dollar sign character in mns file

    Registered forum members do not see this ad.

    Hi,

    I'm working on an acad2000 menu code (mns file) and am having trouble with the dollar symbol. It is being interpreted as a diesel expression and I don't want that.

    Here is a line of code:

    Code:
    [5mm Vertical Drill]*^C^C_osmode 2 -layer s TCHW0B2TCD$DR5.2$D100 ;-insert V5 \ ;;_xplode _l ;i
    This is how my system works. I have a menu that loads a template containing predefined layers and blocks. Some of those layer names contain '$' symbols and are a necessary requirement. In the above example, I will select the '5mm vertical drill' option in my menu which is associated with the predefined 'TCHW0B2TCD$DR5.2$D100' layer name. The problem is acad only reads 'TCHW0B2TCD' because the '$' character in the mns. file is being interpreted as a diesel expression and the association with the predefined layer name fails.

    I've tried replacing the dollar symbol with '(chr)36' but that doesn't work. I've tried various combinations of quotation marks to no avail as well.

    Is there any way around this problem?

  2. #2
    Quantum Mechanic ReMark's Avatar
    Computer Details
    ReMark's Computer Details
    Operating System:
    Windows 7 Pro 64-bit
    Computer:
    Thinkmate
    Motherboard:
    Intel DX58SO2 LGA1366 X58
    CPU:
    Intel i7-960 Quad-core 3.20GHz 8MB cache
    RAM:
    12GB (3x4GB) PC3-106000 DDR3
    Graphics:
    nVidia Quadro 4000, 2GB GDDR5
    Primary Storage:
    150GB Velocipraptor 10,000 rpm
    Secondary Storage:
    none
    Monitor:
    Dell P24LLH - 24" wide screen LCD
    Discipline
    See details...
    ReMark's Discipline Details
    Occupation
    CAD Draftsman/Designer...chemical manufacturing.
    Discipline
    See details below.
    Details
    I work for a specialty chemical manufacturer. I do a little bit of everything from P&IDs to civil to architectural and structural.
    Using
    AutoCAD 2015
    Join Date
    Nov 2005
    Location
    Norwalk, CT USofA
    Posts
    39,691

    Default

    Take the "$" out of your layer name altogether.

    From what I can recall the < $ > is a special character code for loading a menu area. When AutoCAD reads your layer name and gets to the $D portion it expects to see something far different than what you are providing.

    Example: $P0=SNAP
    Last edited by ReMark; 9th Dec 2010 at 12:54 pm.
    "I have only come here seeking knowledge. Things they wouldn't teach me of in college." The Police

    Eat brains...gain more knowledge! I've gone over to the dark side.

  3. #3
    Forum Newbie
    Using
    AutoCAD 2000
    Join Date
    Nov 2010
    Posts
    6

    Default

    Some of those layer names contain '$' symbols and are a necessary requirement
    How about a wildcard selection? If possible, how could I write the code for that?

  4. #4
    Quantum Mechanic ReMark's Avatar
    Computer Details
    ReMark's Computer Details
    Operating System:
    Windows 7 Pro 64-bit
    Computer:
    Thinkmate
    Motherboard:
    Intel DX58SO2 LGA1366 X58
    CPU:
    Intel i7-960 Quad-core 3.20GHz 8MB cache
    RAM:
    12GB (3x4GB) PC3-106000 DDR3
    Graphics:
    nVidia Quadro 4000, 2GB GDDR5
    Primary Storage:
    150GB Velocipraptor 10,000 rpm
    Secondary Storage:
    none
    Monitor:
    Dell P24LLH - 24" wide screen LCD
    Discipline
    See details...
    ReMark's Discipline Details
    Occupation
    CAD Draftsman/Designer...chemical manufacturing.
    Discipline
    See details below.
    Details
    I work for a specialty chemical manufacturer. I do a little bit of everything from P&IDs to civil to architectural and structural.
    Using
    AutoCAD 2015
    Join Date
    Nov 2005
    Location
    Norwalk, CT USofA
    Posts
    39,691

    Default

    Sorry, but it has been a while since I did something like this. I cannot rightly recall.
    "I have only come here seeking knowledge. Things they wouldn't teach me of in college." The Police

    Eat brains...gain more knowledge! I've gone over to the dark side.

  5. #5
    Quantum Mechanic Lee Mac's Avatar
    Computer Details
    Lee Mac's Computer Details
    Operating System:
    Windows 7 Ultimate (32-bit)
    Discipline
    Multi-disciplinary
    Lee Mac's Discipline Details
    Discipline
    Multi-disciplinary
    Details
    Custom Programming / Software Customisation
    Using
    AutoCAD 2013
    Join Date
    Aug 2008
    Location
    London, England
    Posts
    16,762

    Default

    Quote Originally Posted by jason_a View Post
    How about a wildcard selection? If possible, how could I write the code for that?
    Write a code for what exactly?
    Lee Mac ProgrammingTwitterExchange App StoreDropbox (500MB free)

    With Mathematics there is the possibility of perfect rigour, so why settle for less?

  6. #6
    Quantum Mechanic ReMark's Avatar
    Computer Details
    ReMark's Computer Details
    Operating System:
    Windows 7 Pro 64-bit
    Computer:
    Thinkmate
    Motherboard:
    Intel DX58SO2 LGA1366 X58
    CPU:
    Intel i7-960 Quad-core 3.20GHz 8MB cache
    RAM:
    12GB (3x4GB) PC3-106000 DDR3
    Graphics:
    nVidia Quadro 4000, 2GB GDDR5
    Primary Storage:
    150GB Velocipraptor 10,000 rpm
    Secondary Storage:
    none
    Monitor:
    Dell P24LLH - 24" wide screen LCD
    Discipline
    See details...
    ReMark's Discipline Details
    Occupation
    CAD Draftsman/Designer...chemical manufacturing.
    Discipline
    See details below.
    Details
    I work for a specialty chemical manufacturer. I do a little bit of everything from P&IDs to civil to architectural and structural.
    Using
    AutoCAD 2015
    Join Date
    Nov 2005
    Location
    Norwalk, CT USofA
    Posts
    39,691

    Default

    I think the OP is trying to find a wild card replacement for his layer naming convention.
    "I have only come here seeking knowledge. Things they wouldn't teach me of in college." The Police

    Eat brains...gain more knowledge! I've gone over to the dark side.

  7. #7
    Luminous Being
    Using
    Civil 3D 2013
    Join Date
    Dec 2005
    Location
    GEELONG AUSTRALIA
    Posts
    5,092

    Default

    Probably better of with - or _ in layer names rather than dollar sign $ should never use any of the special symbols in any sort of naming !@#$%^&*()+ also watch out for space works ok for naming but programming can cause head aches. If you want to continue try making the layer name a lisp variable

    [5mm Vertical Drill]*^C^C(setq layname "TCHW0B2TCD$DR5.2$D1") _osmode 2 -layer s !layname

  8. #8
    Super Member MarcoW's Avatar
    Computer Details
    MarcoW's Computer Details
    Operating System:
    Microsoft Windows 7 Pro 64-bit
    Computer:
    A black one
    CPU:
    Intel Xeon E5520 Quad Core
    RAM:
    8 GB
    Graphics:
    NVIDIA Quadro FX 580 - 512MB
    Primary Storage:
    300 GB 10000 RPM
    Using
    AutoCAD 2011
    Join Date
    Apr 2009
    Location
    The Netherlands
    Posts
    599

    Default

    Registered forum members do not see this ad.

    I once had the trouble with a "&" sign in a *.mnu file.
    The solution was simple: just type "&&" and it is shown as "&".
    But in your case I cannot tell for shure if this works...
    GOod luck with it!

Similar Threads

  1. no plus sign in CUI
    By khoshravan in forum AutoCAD Beginners' Area
    Replies: 0
    Last Post: 4th Jul 2010, 04:08 am
  2. No @ sign
    By gordongxg in forum AutoCAD 2D Drafting, Object Properties & Interface
    Replies: 13
    Last Post: 10th Mar 2008, 01:05 pm
  3. 'per thousand'-sign
    By Tiger in forum AutoCAD Drawing Management & Output
    Replies: 10
    Last Post: 28th Aug 2007, 07:29 pm
  4. North Sign
    By keithwhoriskey in forum AutoCAD Beginners' Area
    Replies: 2
    Last Post: 6th Feb 2006, 06:57 pm

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts