I am aware there was a previous topic (called Dyanmo “is input” through pyRevit) on converting Dynamo inputs into pyRevit. However my dynamo code has 2 inputs, one is select the element you want to rotate and the other is the number of deg to rotate.
No, you can’t,
But what you can do is ‘translate’ it. What I mean by that is that you can reuse bits and pieces of code from one to reuse in the other.
Replacing the frameworks specific items like the IN and OUT variable from dynamo, or the dynamoDS bits
That was exactly my plan, to get the user to select the elements first and then somehow have an input through either pyrevit itself or a datashapes node
Please excuse me if this is a stupid question but i am fairly fresh to all this but how exactly would i use that code? I assume i would put into a python node inside of the dynamo script? if so i have tried with the following code however do not appear to be having any luck
OK so you just suggested to not use dynamo at all @Jean-Marc .
That leads us to the question why do you want to use a dynamo script and not a pyRevit script @Wilko1306 ?
Oh sorry, you have to first define uidoc to use the function:
I am very fresh to the scene of coding and pyrevit. I have various existing dynamo script that works and i am trying to integrate them into pyRevit and that is why i currently am working with a dynamo script rather than python
In this specific case i am trying to make it possible to take any number of columns (that are selected) and rotate them around there centroid as currently you would have to do that individually for each column using the normal rotate command