# Background Open File - Delete Views

**URL:** <https://forum.dynamobim.com/t/background-open-file-delete-views/42565>\
**Category:** Revit\
**Tags:** clockwork, dynamo\
**Created:** [October 31, 2019, 10:50am UTC](https://forum.dynamobim.com/t/background-open-file-delete-views/42565 "2019-10-31T10:50:17Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![b.ross](https://avatars.discourse-cdn.com/v4/letter/b/50afbb/32.png) [@b.ross](https://forum.dynamobim.com/u/b.ross)\
**Post date:** [October 31, 2019, 10:50am UTC](https://forum.dynamobim.com/t/background-open-file-delete-views/42565/1 "2019-10-31T10:50:17Z")

</div>

Hi All,

Im having trouble getting views from a document open in the background, using a simular method described in the thread here: [Open File, Delete Views, Close and Save](https://forum.dynamobim.com/t/open-file-delete-views-close-and-save/22465/3).

The 'Super Collector Views From Document" node seems to be returning ‘nulls’ for all items. can anyone see if i’m missing a step?

@Andreas_Dieckmann, any chance you could take a look?

 ![Capture](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/e/4/e43aa74f6fca9697588e7f16d0c9ea7b72049e48.png)

---

<div class="post-metadata">

**Author:** ![Marcel\_Rijsmus](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/marcel_rijsmus/32/8539_2.png) [@Marcel\_Rijsmus](https://forum.dynamobim.com/u/Marcel_Rijsmus)\
**Post date:** [October 31, 2019, 12:43pm UTC](https://forum.dynamobim.com/t/background-open-file-delete-views/42565/2 "2019-10-31T12:43:48Z")

</div>

You cannot delete all views in Revit, so you cannot delete all views in Dynamo.  
There needs to be a least one view.

---

<div class="post-metadata">

**Author:** ![b.ross](https://avatars.discourse-cdn.com/v4/letter/b/50afbb/32.png) [@b.ross](https://forum.dynamobim.com/u/b.ross)\
**Post date:** [October 31, 2019, 12:57pm UTC](https://forum.dynamobim.com/t/background-open-file-delete-views/42565/3 "2019-10-31T12:57:35Z")

</div>

Marcel, im aware. the screenshot is an extract of a larger script where selected views are excluded from the list before detletion.

As shown above, the problem is in creating the list of sheets.

---

<div class="post-metadata">

**Author:** ![jacob.small](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/jacob.small/32/161030_2.png) [@jacob.small](https://forum.dynamobim.com/u/jacob.small)\
**Post date:** [October 31, 2019, 1:29pm UTC](https://forum.dynamobim.com/t/background-open-file-delete-views/42565/4 "2019-10-31T13:29:25Z")

</div>

Andrea’s work is built in a very accessible way, so there may be no need for you to wait for him or others to solve this for you.

Double click on the super connector node and you’ll open the node so you can edit/review it. I’m there will be all the nodes which make up the node. Copy all of those to the clipboard except the inputs and outputs, switch back to your main file, and wire them in as if they were the custom node. Run the graph and see where the error is.

---

<div class="post-metadata">

**Author:** ![john\_pierson](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/john_pierson/32/191977_2.png) [@john\_pierson](https://forum.dynamobim.com/u/john_pierson)\
**Post date:** [October 31, 2019, 1:35pm UTC](https://forum.dynamobim.com/t/background-open-file-delete-views/42565/5 "2019-10-31T13:35:01Z")

</div>

> [@jacob.small](#):
>
> Andrea’s work is built in a very accessible way, so there may be no need for you to wait for him or others to solve this for you.
> 
> Double click on the super connector node and you’ll open the node so you can edit/review it.

Super Collector is not in Clockwork…  
 ![image](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/a/d/ad374b432be28bd9cb92ed5b5eaf0e99891c73db.png)

---

<div class="post-metadata">

**Author:** ![jacob.small](https://sea2.discourse-cdn.com/flex022/user_avatar/forum.dynamobim.com/jacob.small/32/161030_2.png) [@jacob.small](https://forum.dynamobim.com/u/jacob.small)\
**Post date:** [October 31, 2019, 1:43pm UTC](https://forum.dynamobim.com/t/background-open-file-delete-views/42565/6 "2019-10-31T13:43:57Z")

</div>

Ah!!! Good catch. Thanks @john_pierson. Dyf file’s are dyf file’s though so the same holds true. 🙂

---

<div class="post-metadata">

**Author:** ![b.ross](https://avatars.discourse-cdn.com/v4/letter/b/50afbb/32.png) [@b.ross](https://forum.dynamobim.com/u/b.ross)\
**Post date:** [October 31, 2019, 2:29pm UTC](https://forum.dynamobim.com/t/background-open-file-delete-views/42565/7 "2019-10-31T14:29:18Z")

</div>

Good spot john. Bakery it is.

Super collector requires a document, while i was trying to input a list. solved using list.getitematindex

Jacob, thanks for encouraging me to be less lazy.

 ![Annotation%202019-10-31%20141422](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/b/1/b12796bcf6affec09fe73c8d94be4549eab41f62.png)

 ![Annotation%202019-10-31%201427072](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/3/2/32ac5d89c3756b92d8c5f0e4aaaf28ce74ad9f72.png)
