I have two scripts that are built very similarly. One works fine and the other does not. I am trying to figure out what has gone wrong with the second one but I am having zero luck.
The first script looks for views with a TXXX and replaced them with a proper project number.
The second script is taking views that are not on a sheet and attempts to rename them with a “NOS_” prefix. This script is throwing a “The name entered is already in use. Enter a unique name.” warning but there are no duplicate names. It seems to be taking the first value from the list and trying to apply it to each view (hence the warning). The first script replaced multiple view names but works just fine.
RenameCBSViewsToProjectNumber.dyn (32.8 KB)
RenameDetailsWithSheetAndNumber2.dyn (23.8 KB)