Exemplo n.º 1
0
        public static void SetElementForTrace(string handle)
        {
            SerializableHandle tracedHandle = new SerializableHandle();

            tracedHandle.Handle = handle;

            DynamoServices.TraceUtils.SetTraceData(REVIT_TRACE_ID, tracedHandle);
        }
        public static string GetHandleFromTrace()
        {
            ISerializable traceData = DynamoServices.TraceUtils.GetTraceData(REVIT_TRACE_ID);

            SerializableHandle handle = traceData as SerializableHandle;

            if (handle == null)
            {
                return(null); //There was no usable data in the trace cache
            }
            return(handle.stringID);
        }
        public static void SetElementForTrace(String handle)
        {
            if (!IsEnabled)
            {
                return;
            }

            SerializableHandle hand = new SerializableHandle();

            hand.stringID = handle;

            DynamoServices.TraceUtils.SetTraceData(REVIT_TRACE_ID, hand);
        }