Revit Template with Hyperlink Object to point dynamo to play folder

dynamo

#1

Anyone seen any or have ideas on how to incorporate a link in Revit templates to point Dynamo to a particular project’s library folder?

I.e. Start a template - then on the front splash page click a object link to point dynamo player to a specific folder to play e.g. Load worksets, Link to excel, etc?

Be great if we could incorporate the Dynamo settings in the templates!


#2

You could probably wright a dynamo script to direct the player to a folder. I know you can do this for dynamo for the recent files shown on the home screen. Place these scripts in every dynamo player folder and then you could change between them?

I guess you could add some project parameters (maybe a global parameter) and input the info needed to run a graph. Then write your scrips to read that parameter rather than a direct user input.

Food for thought. I have not tried any of these.


#3

We have a batch file that runs on everyone’s machine and sets all their Dynamo settings files to the locations that we want. If you want to do this on a project level you could get the current model location and use that to find the local Dynamo folder for the given project and then specify that location in the user’s settings file. It would probably require a batch routine somewhere. Or you’d have to have a Dynamo script created that would do it for you. But then you have the same problem of getting the user to run the correct Dynamo script to setup their project location.


#4

This would work, but changing between projects would be difficult.

Out of curiosity, are your dynamo player scripts that different between projects that you have multiple script repositories instead of one which is reused on all jobs with variable inputs?


#5

Correct. And I don’t want to overwhelm my users with lists of hundred or so scripts when 2 to 5 specific per project is all they will need. (I.e. create work sets different per client)


#6

If everyone has there own 2 to 5 scrips how do you handle updating them? I guess you could create a dynamo graph for that as well but seams easy to have things fall through the cracks.


#7

Central library where those scripts reside per client (not per person).
Librarians maintain manage and update the library as needed.


#8

I think the main issue here is that the files that determine the Dynamo Player “library” are encrypted. It’s not as easy as saying “point to this location.”

I’ve played around with something similar for standardized program libraries. But in order to do this I have to manually copy those encrypted files for each program library I want. The process looks something like this:

  1. Manually point Player to Library1.
  2. Copy encrypted files to Lookup Folder/Library1.
  3. Repeat Step 1 and 2 for Library2, Library3, etc.

The goal here is to set up a directory that has the encrypted “library” files for each program I have. Then I can run my Dynamo script that has the user select a program, and overwrites the user’s current settings with the encrypted “library” files from the specified program’s lookup location.

So if you wanted to do this for specific projects you would have to manually create a lookup for each project using Dynamo. It’s possible, but it’s a lot of work. Maybe you could write a Dynamo script to do it for you… :wink:


#9

Seems like the only way to change the player settings is to copy the entire “settings” folder from machine to machine … yuck

If you’re really determined to do this, you can probably have some document macro in Revit that deletes all folders in ‘c:\Users\YOURUSER\AppData\Local\dynamoplayer\User data’ and replaces it with a new one that has the correct path (which you could for example store together with the project)


Multiple Folders in Player
#10

In order to change where Dynamo Player defaults to looking for scripts you only need to copy the two encrypted files located here: AppData\Local\dynamoplayer\User data\dynamoplayerinstance 1\Default\Local Storage

There’s another file (I think Preferences) that forces the directory to open to the same location, but that’s not necessary to get this process to work.

This is the graph I use: