Currently there is an issue in Revit when you try to use the “GetParameterByName” node in Dynamo to retrieve viewport names.
If you have a title on sheet parameter defined it starts to throw some weird errors.
Luckily we have all of the nodes in Dynamo to filter out what we want!
Rather than rebuild this whole graph I made this nice little collector which is now on Rhythm.
The original question about this can be found here http://dynamobim.com/forums/topic/revit-viewports-not-cooperating/#post-19655