hi all,
python/ form question, just want a return value of “False” if form was cancelled and “True” if user press Ok/ Yes? would that be possible? Thanks in advance.
import clr
import msvcrt
clr.AddReference("RevitAPIUI")
from Autodesk.Revit.UI import *
clr.AddReference("RevitServices")
import RevitServices
from RevitServices.Persistence import DocumentManager
doc = DocumentManager.Instance.CurrentDBDocument
uidoc=DocumentManager.Instance.CurrentUIApplication.ActiveUIDocument
clr.AddReference("RevitNodes")
import Revit
clr.ImportExtensions(Revit.Elements)
buttons = TaskDialogCommonButtons.No| TaskDialogCommonButtons.Yes
result = TaskDialogResult.Ok
TaskDialog.Show('Revit',"Confirm?",buttons)