I’m working on a file upgrader which uses nodes from the Rhythm package, and everything seems to work OK so far, but after I iterate through all the subdirectories to create a list of all my files, how can I filter out everything except .rfa .rvt and .rte files?
We’ve got quite a few files of other formats scattered around our library such as .txt, .xls and .png files, the Document.BackgroundOpen node obviously hangs when it gets to a filetype which is not native to Revit.
Thanks very much Einar & Dimitar - the recursive directory search and sting filter are way more elegant than what I had, which was about 10 levels of directory contents nodes to discover all the files, and then I was trying to filter them after compiling the list.
One more question; now that I have a working dynamo file, is there away to send someone my .dyn file so they can run it on their machines (with revit/dynamo installed), but without them having to install the clockwork and rhythm packages separately?
i.e. is there a way to “compile” just those custom nodes into my file?
I want to share this with a couple of other Revit users who don’t use dynamo, so the simpler I can make it for them to use, the better.
[quote=“rad1cal, post:5, topic:11890”]
is there away to send someone my .dyn file so they can run it on their machines (with revit/dynamo installed), but without them having to install the clockwork and rhythm packages separately?
[/quote]Compilation or pack-and-go would be nice. If the DYFs are in the same folder as your DYN and you transmit the whole folder, it should work on another’s machine. You’d have to test it, though (DLLs?).
Short answer: no. But if the node is simply a python block you can copy that directly into your graph and essentially “remove” the custom nodes. You can also do this with custom nodes made of other nodes, but this can sometimes cause issues with lists, lacing, or other nested nodes.