Hi,
Is there a way to prevent Revit from deleting a group from the project when LastCopyOfGroupDeleted is triggered?
I have one attached detail group that is removed from the project when deleted, both when using the Attached Detail Group Placement dialog and the delete action. Others do not get this error, even if the last copy is removed.
A work-around is changing the type of the detail group to another attached detail group, then deleting that one. Obviously this won't work if there is only 1 detail group attached to the model group.
What is the difference between the attached detail groups that are deleted, and those that aren't?
How can I prevent it from happening?
Thanks!
Not sure if I'm interpreting the problem completely.
But attached detail groups that have a model instance existing exist within the model group, where as if its not attached it has nothing hosting it (?) taking a stab there.
Is there a reason you don't just use a detail family instead of a detail group?
If you copied all of your notation across to a generic detail family you could delete/place as you wish and it wouldn't disappear from your project until you actively delete it or purge the model.
@psmGBPVX wrote:Not sure if I'm interpreting the problem completely.
But attached detail groups that have a model instance existing exist within the model group, where as if its not attached it has nothing hosting it (?) taking a stab there.
Yes, it's a group that contains tags for windows and such, as well as dimensions.
We're not using families, because as far as I know, the tags need to be in an attached detail group. We have many instances of the same group, so this seems to be the easiest way to add the dimensions.
I'll look into the detail families, but my colleagues are not very keen on them.
Thanks
hopefully this helps
from this link LastCopyOfGroupDeleted
There are three types of groups in Revit; Model Group, Detail Group, and Attached Detail Group. All are created using the NewGroup() method. The created Group's type depends on the Elements passed.
When elements are grouped, they cannot be moved or rotated. If you perform these operations on the grouped elements, nothing happens to the elements, though the Move() or Rotate() method returns true.
You cannot group dimensions and tags without grouping the elements they reference. If you do, the API call will fail.
You can group dimensions and tags that refer to model elements in a model group. The dimensions and tags are added to an attached detail group. The attached detail group cannot be moved, copied, rotated, arrayed, or mirrored without doing the same to the parent group.
try removing the annotative tags dimensions etc. to create a MODEL group then apply dimensions and tags as needed. this can be done with an enlarged plan of that grouped area
Right, ok yeah tags etc don't really work hosted in a detail family.
There are workarounds you could do with either phases or worksets where you have a group that exist in perpetuity in the background on a phase/set that is turned off, but i don't really like advising that kind of thing as its not very neat.
Running into this myself with Revit 2021 as well and I am not seeing a solution to it. For the majority of views and their respective attached detail groups this delete warning is not triggered when turning the attached detail group off, but for a few the warning comes up and we lose the persistence of the attached detail group despite the host model group remaining present in the project.
This error pretty much destroys the usefulness of attached detail groups. I will keep digging in the project and see if the behavior is linked to a specific element that I am adding to the attached detail group.
I have spent a lot of time developing some dynamo tools that rely upon model groups and attached detail groups remaining persistent in a project even when they are not placed, so a fix or workaround would be great.
Hi,
AFAIK the project browser always keep a "non placed" instance of groups despite all instances in model were deleted, in fact, you know when there is no instance of a group or family in model by selecting it in the project browser, right-click and then "select all instances in model": if there is only one (1) indicated but greyed out in Properties palette means there is no instance in model but you can create one right-clicking again. I suggest three inelegant solutions: 1) pin a group instance; 2) create a "container" phase and throw; 3) save group andf keep it for future loads.
Hope this will help,
Thanks for the quick response. That is the expected behavior that I want. Making the dynamo tools I had to become familiar with the difference of GroupType in the Revit API as that is exactly what I expect to persist when an instance of a Group or Attached Detail Group is removed from all views...yet this warning is coming up and it proceeds to completely remove the types from the project on it's own. I have seen it do so a few times even without the warning...but I believe I have narrowed it down to a dimension reference that it is struggling with.
It also seems to be mixing with the warning "can't make change to group with more than one instance" when editing the Attached Detail Group. This also seems to lead to inability to place the compromised Attached Detail Group on any other instance of the associated group. Maybe this is just Revit's way of weeding out corrupt data as per usual
I am going to try going back into a previous version of my file and see if I can track all of the errors back to dimension references.
Sie finden nicht, was Sie suchen? Fragen Sie die Community oder teilen Sie Ihr Wissen mit anderen.