Hello dear friends.
I need to create a Callout View inside Revit, and then trim it and assign a ViewType and ViewTemplate parameters to it.
There is no such node in RhinoInsideRevit plugin so I decided to code it with Python. There is a method in Revit API CreateCallout()
However, I run into a problem, when I try to generate a Callout view - it freezes both Revit and Rhino. The only thing I can do, is to close them both via terminal. This issue makes it impossible for me to debug the code, because the programs just freeze.
I created this test script to recreate the problem. If you press the button - Revit and Rhino will freeze. However, if you unplug the deactivated component from it, the Callout View will be successfully created. This is not the only thing that makes the script to freeze the programs, it is just one of them. For example if there is some error produced by any RIR component, this script will also freeze.
CreateCallout_6.gh (165.9 KB)
createCalloutPython.py (2.0 KB)
I am using Windows 10, Revit 2021.1.2, Rhino 7.
I searched in Autodesk forum, as well as here, and couldn’t find a solution. I also searched in Revit logs, but when it freezes, I don’t see this transaction. This is how a successful transaction looks like:
1:<
Jrn.Data “Transaction Successful” _
, “Add Section View”
’ 0:< API_SUCCESS { Unregistering DialogBoxShowing event by application Rhino.Inside (02eff7f0-4921-4fd3-91f6-a87b6ba9bf74). }
’ 0.292541 1:<<<;PERF;MISC;drawing
’ 0:< ::112:: Delta VM: Avail +73 → 134151178 MB, Used -74 → 1888 MB; RAM: Avail +82 → 3505 MB, Used +2 → 1780 MB
’ 0:< GUI Resource Usage GDI: Avail 8698, Used 1302, User: Used 1379
'C 11-Nov-2023 13:20:15.842; 0:< Executing AddInJournaling : WinformWindow(GH_DocumentEditor,Grasshopper - CreateCallout_4*).WinformToolStrip(0,CanvasToolbar).Click(SaveButton)
'E 11-Nov-2023 13:20:15.843; 0:<
Jrn.AddInEvent “AddInJournaling” , “WinformWindow(GH_DocumentEditor,Grasshopper - CreateCallout_4*).WinformToolStrip(0,CanvasToolbar).Click(SaveButton)”
’ 1:< ::113:: Delta VM: Avail +31 → 134151210 MB, Used +1 → 1889 MB; RAM: Avail +6 → 3512 MB, Used +0 → 1781 MB
’ 1:< GUI Resource Usage GDI: Avail 8697, Used 1303, User: Used 1378
'H 11-Nov-2023 13:20:17.572; 1:<
Jrn.Data “Transaction Successful” _
, “Create Callout”
’ 0:< ::113:: Delta VM: Avail -32 → 134151178 MB, Used 1889 MB; RAM: Avail -36 → 3476 MB, Used 1781 MB
’ 0:< GUI Resource Usage GDI: Avail 8700, Used 1300, User: Used 1378
'E 11-Nov-2023 13:20:25.254; 0:<
Jrn.Browser “Activate” _
, " "
’ 0:< <>
’
'Edit mode: IDR_COMMON
'Command: ID_BUTTON_SELECT
'Category: 0
'Bar list:
’ Dialog_Revit_DynamicLabelDBar
'Provider list:
’ PP_Elements_Are_In_ModScope
'Product: Revit
’
’
'***********************************************************
'***********************************************************
Can anybody help me with that?
Why is that happening and how can I possibly fix that?
Thank you so much!