Issue when attempting to reload a family

Issue when attempting to reload a family

acarpentierNB27W
Contributor Contributor
9,691 Views
9 Replies
Message 1 of 10

Issue when attempting to reload a family

acarpentierNB27W
Contributor
Contributor

Hello everyone,
I am encountering an issue when trying to reload a family.
I have a model with an outdated family but when I try to load in the new family, nothing happens.

The only way to reload the family appears to be to open up the new family, make an edit to it (any edit), save it and then it is able to be reloaded in the model.
This issue does not affect all models, some models can reload it just fine without having to edit it.

Here is an annotated video demonstrating the issue at hand:

Would anyone know why this issue occurs, and if there is a better way to fix it?

Thanks!

0 Likes
9,692 Views
9 Replies
Replies (9)
Message 2 of 10

ralphdenhaan
Collaborator
Collaborator

Hi,

 

I would suggest always reloading the family from within the project browser by right-clicking:

ralphdenhaan_0-1708546587340.png

 

The option: Overwrite the existing version is most safe to use. But the parameter values assigned in the project remain the same.

The second option does change the parameter values assigned inside your family.

Both options do reload your family but for the first option, you have to change the values inside your project while the second option 'copies' the values you set inside the family editor.

 

ralphdenhaan_0-1708546746007.png

 

 

Select Accept as Solution and Likes are always welcome. 


Ralph den Haan, (Lazy) BIM Specialist


LinkedIn | LazyBIM Blog


 

0 Likes
Message 3 of 10

acarpentierNB27W
Contributor
Contributor
Trying to reload from within the project browser by right-clicking results in the same behavior sadly.
0 Likes
Message 4 of 10

Alfredo_Medina
Mentor
Mentor

@acarpentierNB27W  Try it in another project. Most likely it will work.


Alfredo Medina _________________________________________________________________ ______
Licensed Architect (Florida) | Freelance Instructor | Profile on Linkedin
0 Likes
Message 5 of 10

ennujozlagam
Mentor
Mentor

have you try to install latest updates from autodesk and see if helps?





Remember : without the difficult times in your LIFE, you wouldn't be who you are today. Be grateful for the good and the bad. ANGER doesn't solve anything. It builds nothing, but it can destroy everything...
Please mark this response as "Accept as Solution" if it answers your question. Kudos gladly accepted.
0 Likes
Message 6 of 10

RSomppi
Mentor
Mentor

Your last reload shows a backup file (*.001) that wasn't present in the previous windows. There was a save between the before and after reloads.

0 Likes
Message 7 of 10

acarpentierNB27W
Contributor
Contributor

@Alfredo_Medina yes it works on other projects. But I need it to work on all projects as we have updaters that rely on the right version of the family being loaded.

 

@ennujozlagam Several users have reported that odd behavior, regardless of whether they were up to date with their software or not.


@RSomppi Yes, in the video I deleted a dimension from the family file and saved the family to force an update of the rfa file, allowing me then to reload it in my project.

But the family loaded in the project is an older version already, so I shouldn't need to update my family file to enable it to be reloaded. I should have been able to reload it without having to edit the rfa file. That's the core of the issue I am experiencing.


0 Likes
Message 8 of 10

aganem5XUT7
Participant
Participant

@acarpentierNB27W I have this exact behavior consistent across all projects in Revit 2023 (have not tested later versions)

It is extremely annoying... This behavior affects the Project Browser -> Reload and even if you reload via Revit API. What I think happens Revit thinks the families are the same, so it skips the reload (why they did that i do not know... the easiest and most effective thing to do would be just to reload them regardless). Revit does not notice changes of new types created (and something else, can't remember of top of my head). It does notice the undo history. So, what I do is edit family, draw a line, delete the line, then reload...

Another issue I noticed with Project Browser -> Reload, if you reload family with exact same name from a different directory, it skips that reload. So, the trick is to add a suffix to the family you are reloading (Rename Family to FamilyZZZ in Project Browser, and then reload FamilyZZZ from Family in a different directory)

I am switching to newer Revit soon, so curious if Autodesk picked these up...

Message 9 of 10

TripleM-Dev.net
Advisor
Advisor

If no edits are made to the family (in the editor) the family won't be seen as edited by Revit.

So adding a type to a family in the project and then loading that family into another project, won't trigger the "Overwrite warning" and new types won't come over to the other project.

 

Creating a new type IN THE FAMILY EDITOR will be enough to trigger this (I mostly create a new type and delete it so if I need to trigger the overwrite option to get new types into another model (or overwrite type values)

 

- Michel

0 Likes
Message 10 of 10

aganem5XUT7
Participant
Participant

@TripleM-Dev.net 

I did not experience this. I did something dumb recently... I purged a couple of my container files containing hundreds of families... Lost all my types.  Families in the library still had all the types. I caught this way too late to be able to use backups without paranoia.

So, I figured a simple reload all families would fix it... but it did not. I used the following code:

                        // Edit the family document to get the file path
                        Document familyDoc = doc.EditFamily(family);
                        string familyPath = familyDoc.PathName;
                        report.AppendLine("\n\nFamily path: " + familyPath);
                        familyDoc.Close(false);

                        if (!string.IsNullOrEmpty(familyPath) && File.Exists(familyPath))
                        {
                            string originalFamilyName = family.Name;

                            report.AppendLine("\n\nAttempting to reload family from: " + familyPath);

                            // Reload family from the file path
                            using (Transaction trans = new Transaction(doc, "\n\nReload Family - " + originalFamilyName))
                            {
                                trans.Start();
                                if (doc.LoadFamily(familyPath, new FamilyOption(), out Family reloadedFamily))
                                {
                                    report.AppendLine("\n\nSuccessfully reloaded family: " + originalFamilyName);
                                    counterReloaded++;
                                }
                                else
                                {
                                    report.AppendLine("\n\nFailed to reload family: " + originalFamilyName);
                                }
                                trans.Commit();
                            }
                        }
                        else
                        {
                            report.AppendLine("\n\nFailed to reload " + family.Name + ". Path not found or invalid: " + familyPath);
                        }


What I ended up doing, is modify Cost parameter in every family in the library, save it, and then set the Cost parameter to 0, and save it again (using Revit API lol... not sure if all the extra saving was necessary but I did not want to take chances or spend more time experimenting). Cost is a parameter we never use so it is a safe modification. After this, the above Revit API code to reload families worked and brought all the types to my container files. This is fresh off the press as I just finished doing this about an hour ago in Revit 2023...


0 Likes