Jump to content

Recommended Posts

Posted

Hi there,

 

When inserting a new layout from a template file, by using the command "-layout" "template"etc., in a new drawing this is working fine.

 

Now, when doing the same thing again, AutoCAD returns me this message on the command line:

 

Unit-scaling inserted database...Duplicate definition of layer state 
"ACAD_VIEWS_1st_floor" ignored.Duplicate definition of layer state  
"ACAD_VIEWS_Basement" ignored.Duplicate definition of layer state 
"ACAD_VIEWS_Unit" ignored.

 

I went through everything I could think of, and of course the layer state manager. But I cannot find where those "ACAD_VIEWS" are stored.

 

Obviously it is importing something wich is already there: hence the message.

 

Any thoughts on this one? Thanks in advance!

Posted

I believe it means you're inserting something that has layer states with the same name as the layer states that already exist in the drawing, so it's ignoring the new layer states definition and using the ones already in the drawings.

 

The same thing happens if you try to insert a block with the same name as a block that's already in the drawing.

Posted

So the question is where to look in the *.dwg for the views so I can delete them. In that case there are no views or layerstates that can be duplicated...

Any idea?

Posted

LAYERSTATE from the command line, or the 3rd button from the left in the Layer Manager

 

Layerstate.JPG

Posted

Thanks for the reply Nestly but that is where I have checked.

It's not in there....

 

There is only one block definition in the drawing but even if I explore that one I cannot figure this out... beats me :-\

Posted

I tried it with AutoCAD2011, and the message I got was similar, but worded differently when I tried to insert a layout with layerstate name that was already in the drawing, so I'm not sure if it's actually something different, or just a change in wording between 2009 and 2011.

 

Command:   <Layout from Template>
Duplicate definition of layer state "test" ignored.
Command:

Can you post the template? (you have to change the extension to .dwg as the forum software won't allow .dwt files to be attached)

Posted

Found the answer here. Look at page 14 where it says:

 

Layer State LISP APIs

In AutoCAD 2008, a new set of API functions was

added to allow LISP access to the most common layer state operations. The

new functions are as follows:(layerstate-addlayers) Adds/updates a series of

layers to a layer state(layerstate-delete) Deletes a layer

state(layerstate-export) Exports a layer state to an .LAS

file(layerstate-getlayers) Returns a list of the layers saved in a layer

state(layerstate-has) Checks if a layer state is present in the

drawing(layerstate-import) Imports a layer state from a specified .LAS

file(layerstate-rename) Renames a layer state(layerstate-restore) Restores a

layer state into the current drawing(layerstate-save) Saves a layer state in the

current drawingCheck your AutoCAD help for specific usage details.

When you

save a new view in AutoCAD there is an option to save a layer snapshot with the

view. This snapshot is a standard layer state that is flagged as hidden so

it won’t show up in lists in the usual places. They are typically saved

with the following naming convention:

“ACAD_VIEWS_viewname”.

These

won’t show in the

Layer States Manager

list nor will they be listed

in the -LAYER command but they can

still

be accessed and

manipulated like any other layer state using -LAYER or the layer state LISP

functions

 

So that is a stupid function to have in AutoCAD. Anyway I deleted the views and there is no more error.

 

Thanks Nestly for your kind help, hope you appreciate me sharing the solution!

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...