nannz Posted April 9, 2017 Share Posted April 9, 2017 Hi, I want to update the layer automatically from the master xref on the drawings without making the layerstate on the master Xref. I want the layer from the Master Xref updated in the drawing not the layer from the child xref. "I have xref name a, b, c and I created master xref name A by attaching the xref a, b, c. I have a drawing named 001, 002 and 003. I have attached mater xref A in this drawing. Now I changed the layer color of the xref a, b, c in the master xref A. I want these changes to get reflecting on the drawings 001, 002 and 003 without making the layer state on the mater xref A". Do we have any Lisp Routine. If someone could help me with this urgently that would be great. Quote Link to comment Share on other sites More sharing options...
Dadgad Posted April 10, 2017 Share Posted April 10, 2017 Welcome to CADTutor. If I understand you correctly, all you need to do is use the XREF command, to access the Xref Dialog, then right click on Master Xref A in the dialog, and choose RELOAD from the drop down menu. It might be helpful to know what your current VISRETAIN variable setting is, as described in the screenshot. Depending on your VISRETAIN variable setting, if it is set to , the altered color from the parent would be displayed the next time you opened the child. Quote Link to comment Share on other sites More sharing options...
nannz Posted April 10, 2017 Author Share Posted April 10, 2017 Thank you for reply, In this case visretain does not work because i want to update the layer of the master XRef A in the drawing. In the Master ref A i have changed the layer colour of the ref a, b,c and i want to reflect that changes in the drawings. if anyone could help me with this that would be great, because i have many drawings i don't want to manually open the drawing and update the layer state. I just want to be able to type the command, select the mater xref and then select the drawings. Quote Link to comment Share on other sites More sharing options...
Dadgad Posted April 10, 2017 Share Posted April 10, 2017 (edited) Thank you for reply, In this case visretain does not work because i want to update the layer of the master XRef A in the drawing. In the Master ref A i have changed the layer colour of the ref a, b,c and i want to reflect that changes in the drawings. if anyone could help me with this that would be great, because i have many drawings i don't want to manually open the drawing and update the layer state. I just want to be able to type the command, select the mater xref and then select the drawings. Sorry, if I am mistaken, but it still seems to me that if you change your VISRETAIN setting to , close and reopen the drawings you will have accomplished your goal. "When the current drawing is reopened, the layer table is reloaded from the reference drawing and the current drawing reflects those settings. The layer settings affected are On, Off, Freeze, Thaw, Color, Ltype, Lweight, and PStyle (available only in named-plot style drawings)." Should that not be the case, another sure way to go would be with LAYTRANS. Lee Mac has this lisp, which I have never used, which sounds like it may do the trick. http://www.lee-mac.com/resetxreflayers.html Thanks Lee! Edited April 11, 2017 by Dadgad Quote Link to comment Share on other sites More sharing options...
Roy_043 Posted April 10, 2017 Share Posted April 10, 2017 The way I understand the OP: The settings of, let's say, "A|Layer1" have to be copied to "Layer1" in A.dwg. If that is the case then VISRETAIN should not be switched off. Quote Link to comment Share on other sites More sharing options...
nannz Posted April 10, 2017 Author Share Posted April 10, 2017 Thank you guys for the reply!! Do we have lisp routine so that I don't have to open the drawing and update the layers in the drawing from the master xref A Thanks Quote Link to comment Share on other sites More sharing options...
Dadgad Posted April 11, 2017 Share Posted April 11, 2017 (edited) Thank you guys for the reply!! Do we have lisp routine so that I don't have to open the drawing and update the layers in the drawing from the master xref A Thanks Did you look at Lee Mac's lisp, to which I posted the link, in my last post? Edited April 11, 2017 by Dadgad Quote Link to comment Share on other sites More sharing options...
nannz Posted April 11, 2017 Author Share Posted April 11, 2017 yes I tried but didn't work, all the layers in the drawing got updated to what was on the xref a, b, c. I want the drawing to get updated to the layer what was on master xref A. Quote Link to comment Share on other sites More sharing options...
Dadgad Posted April 11, 2017 Share Posted April 11, 2017 Do you understand what the LAYTRANS command does? You might want to look into it. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.