Results 1 to 4 of 4

Thread: Spaces in macro's

  1. #1
    Member
    Join Date
    2005-05
    Posts
    20
    Login to Give a bone
    0

    Question Spaces in macro's

    I am trying to make a macro to turn a specific layer on, and the layer name has spaces in it. The CAD manager doesn't want me to rename the layer, and the macro won't work with spaces in it. Anyone know if there is a workaround to this?

    Thanks,
    Frank

  2. #2
    AUGI Addict Glenn Pope's Avatar
    Join Date
    2001-05
    Location
    Austin, TX USA
    Posts
    2,201
    Login to Give a bone
    0

    Default Re: Spaces in macro's

    Try using quotations ("Layer name") around the layer name.

  3. #3
    The Silent Type Mike.Perry's Avatar
    Join Date
    2000-11
    Posts
    13,656
    Login to Give a bone
    0

    Default Re: Spaces in macro's

    Hi Frank

    Please note I have *moved* this thread from the AutoCAD 2006 General Forum to this one as I feel this particular Forum is a more appropriate place for such a topic.

    Thanks, Mike

    Forum Moderator

  4. #4
    Member G_Sarver's Avatar
    Join Date
    2000-12
    Location
    Maryland
    Posts
    46
    Login to Give a bone
    0

    Default Re: Spaces in macro's

    Quote Originally Posted by frankowen2
    I am trying to make a macro to turn a specific layer on, and the layer name has spaces in it. The CAD manager doesn't want me to rename the layer, and the macro won't work with spaces in it. Anyone know if there is a workaround to this?

    Thanks,
    Frank
    I assume you are structuring your macro something like this:

    ^C^C-layer;on;"test layer";;

    If so simply add quotes around the layer name as I have done.

Similar Threads

  1. Spaces to cope with vertically irregular spaces better
    By Wish List System in forum Revit MEP - Wish List
    Replies: 2
    Last Post: 2015-12-05, 08:10 PM
  2. CP222-2: Autodesk Revit VSTA: Writing Your First Macro An Introduction to the Macro Manager
    By Autodesk University in forum Customization and Programming
    Replies: 0
    Last Post: 2014-12-01, 02:12 AM
  3. Replies: 14
    Last Post: 2010-03-24, 05:13 AM
  4. Challenging Macro to reverse the function of an existing macro
    By parminderkeilah in forum VBA/COM Interop
    Replies: 1
    Last Post: 2008-05-19, 02:50 PM
  5. call script within macro & nested macro
    By wahyudin in forum AutoCAD LT - General
    Replies: 3
    Last Post: 2007-10-22, 01:10 PM

Posting Permissions

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