Creating a new layer and reactors...

Discussion in 'AutoCAD' started by tsigwing, Sep 16, 2003.

  1. tsigwing

    tsigwing Guest

    I have created a reactor that will change the layer of any xrefs that are insert using VLR-beginAttach and it works fine if the layer exists. I have tried to use the (command "layer" "m") but it crashes out at this command, although it works fine at the command prompt. Is there something strange about using (command...) inside the reactor callback?

    Troy
     
    tsigwing, Sep 16, 2003
    #1
  2. tsigwing

    Rudy Tovar Guest

    It's a no-no...

    Don't use commands, because they're not transparent to another command being
    implemented. Also reactors can not stop another command while active.

    Use activeX to create the layer.




    I have created a reactor that will change the layer of any xrefs that are
    insert using VLR-beginAttach and it works fine if the layer exists. I have
    tried to use the (command "layer" "m") but it crashes out at this command,
    although it works fine at the command prompt. Is there something strange
    about using (command...) inside the reactor callback?
    Troy
     
    Rudy Tovar, Sep 16, 2003
    #2
  3. tsigwing

    tsigwing Guest

    OK, got that part working. Another question. Can I change the current layer using VLR-beginAttach or is it too late. Seems to not work. I can create the layer and make it current, but not before the xref insert has occured.
     
    tsigwing, Sep 16, 2003
    #3
  4. tsigwing

    Rudy Tovar Guest

    Why not wait until it's done, then activex change last properties layer.



     



    "tsigwing" <> wrote in message news:...

    OK, got that part working. Another question. Can I change the current layer using VLR-beginAttach or is it too late. Seems to not work. I can create the layer and make it current, but not before the xref insert has occured.
     
    Rudy Tovar, Sep 16, 2003
    #4
  5. tsigwing

    tsigwing Guest

    Couldn't get this to work, so went with the vlr-command-reactor instead.
     
    tsigwing, Sep 17, 2003
    #5
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.