Jump to content

Recommended Posts

Posted

Find and correctly map wrong layers in ACAD group

Hi,
I have a problem with layers grouped in Acad groups. These layers are partially in the wrong group.
Short description:
There are several groups in my drawing in which different layers have to be grouped uniformly.
Certain groups must contain specific layers.
For example, a group includes layers that are somewhere in the layer name "Layer 1".
There is no layer in the drawing that does not belong to a group.
There must be no nested groups.
 
For example, in:
Group A will be all Layer 1.
In group B all Layer 2.
In group C all layers 3.
etc.......

However, it can happen that a wrong layer or several wrong layers were mistakenly assigned to a group.
How can I find the wrong layers in the groups and remove them from the groups and then the right one
Assign groups?
A solution would be a great help.

Martin

Beispielzeichnung.dwg

Posted

You should add what vertical software you're using like Architectural or Mechanical since layer groups don't exist in AutoCAD.

Posted

Hello Tombu,
I do not use layer groups.
I am using Acad group created with the command group.
These groups are assigned specific layers.
I hope that the Gogle translator translates that correctly!🙄

best regards
Martin

Posted

Groups are for objects in the drawing, not layers.  The groups in the NOT CORRECT column all belong to named groups (often multiple ones) while those in CORRECT column are all in unnamed groups (with default names starting with an *).  I've never experienced groups changing on their own, but as Objects can be members of more than one group selecting an object that belongs to multiple groups selects all groups to which that object belongs.  While their objects may be transferred between drawings groups cannot.

Posted

Hello Tombu,
Thank you for your contribution.
The unnamed groups in my example are not wanted.
These were created by copying the left groups.
Of course they should have the same names as the left groups.

I try to find the following Lisp:

Search all named and unnamed groups.
Find out those layers that by default do not belong in this group.
Default would be: "All Layer 1 belong to group A. etc .....
If Layer 1 is found in any group (not in Group A), remove it from this group and add it to Group A.
a layer that is not defined in the predelayers can remain in the group.
Nested groups do not normally exist in my drawing.
If nevertheless a predefined layer should belong to several groups a message should appear and
the program will be stopped.
If another layer should belong to several groups it can stay there and be skipped.
Finally, all predefined layers should be included in the predefined groups.
The predefined layers may not occur in multiple groups.

thanks
Martin

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...