Hey everyone.
i have a project which all the speciel equipment in it has an image parameter which defined as "P.jpg / V.jpg / PV.jpg
I want to batch change all those filenames on image parameter (“סימון קהל יעד”) into a text parameter (“סימון אות קהל יעד”) without the “.jpg” extention) for instance - image parameter says: “P.jpg” > the text parameter will just say “P”
this post is somewhat "cross-posted" into another dynamo forum.but i got the message that it faild to solved. here is the link:
https://forum.dynamobim.com/t/replace-all-image-parameters-into-text-parameters/51403
project: http://telavivinf.com/temp/project%20help.rvt
Gelöst! Gehe zur Lösung
Gelöst von L.Maas. Gehe zur Lösung
I took a different approach. He used some Python code. I did things with the core nodes
-Get all the special equipment in the project (family instances)
-Get the families and then all the family types.
-Get the image from the family types.
-If no image present then drop the type.
-Get the name of the image.
-Removee the extension from the image name
-Write the value in the parameter
In the end some warnings. Because some of the specialty equipment does not have the parameter to wrote to.
You could modify the script to check if parameter is present and then filter them out if not.
As you can see value is written. Some fields are empty because that family has not the required parameter (you would need to add this parameter to the family if needed) or it has no image.
I did not verify if everything correct, so you should do your checks and modifications where needed
Louis
Please mention Revit version, especially when uploading Revit files.
Sie finden nicht, was Sie suchen? Fragen Sie die Community oder teilen Sie Ihr Wissen mit anderen.