Removing revisions from Multiple Sheets

I am trying to write a script that will allow me to delete all revisions on a list of sheets.

I have written a simple script that allows a user to delete all revisions on one sheet.

This works well, but when i try to expand on this and use data-shapes to invoke UI list selection capabilities, it fails, even though the sheets are presented at the end of the data shapes input form as i would expect:

the error points me to line 53 in the python script, but python isnt my strongest point. reading the code it seems it is able to handle multilple sheets but i may be wrong.

I have tried setting lacing to longest and cross product but it still errors out.

(i had to change my autodesk user id so im a brand new user and cant post multiple images yet)

Hi there,
I guess you need a flatten node before Remove Revision Node or a code block list[0] after DataShape node

I guess it is a problem of list levels.

Cheers

Manel

1 Like

tried this and the error has now moved to line 55

the structure seems correct, would flatten not break it? i have 3 lists vs 3

Hi there,

Try to put level 2 in revisions in the RemoveRevision Node

imagen

Cheers

Manel

Manel, thanks for your input, i can feel its getting close, the script now runs, but as there is a number mismatch on the revisions on sheets, its emptying the lowest number of revisions from all sheets and leaving the remainder on the sheets that have more on them

image

Hi,

Try to change lacing to Longest in Remove Revison node

imagen

Cheers

Manel

Manel, im silly, i realised that there is a revision cloud on the sheet, so revit leaves it in place.

im now looking at how to remove the revision clouds as well during this process

thank you for your help!!