I am closing and reopening an active document from the api and in order to this I need to.
Step 1.Open a placeholder document and close my main document.
Step 2.Do this again only opening the original document and closing the place holder.
This requires me to register that the document has closed. unfortunately in i can't do step 2 in the event handler because step 2 also involves closing a document.
So what i need to do is check that the event hander has finished before i start step 2. (I NEED HELP WITH THIS PART)
If I can't register the event in main, I don't mind exploring alternatives
* m_Closehelper closes the opens the new document and closes the current one.
Solved! Go to Solution.
I am basing my code off the building coders article here.
I think I have to use an event becuase it throws an unrecoverable error when i i reopen it too soon so i figgered i had to check to see if the document had fully closed first. i will try your way out in the mean time.
Search the Autodesk Knowledge Network for more content.
Windows 10 Support
Autodesk Online Store Help
Serial Numbers & Product Keys
Installation & Licensing
Online Activation & Registration
Manual Software Activation
Network License Administration
Created by the community for the community, Autodesk Exchange Apps for Revit helps you achieve greater speed, accuracy, and automation from concept to manufacturing.