While working towards getting the Commerce for Umbraco project working in Umbraco 4.5.2 I encountered an issue that didn't appear to have an obvious fix. Luckily, a dive into the Umbraco source code provided an answer.
However, this didn't work in 4.5.2. I always thought this was a bit hacky, and although the code is probably actually doing the same thing the new way looks cleaner:
BasePage.Current.ClientTools .ChangeContentFrameUrl(returnUrl) .ChildNodeCreated() .CloseModalWindow();
You will need to use the following namespaces as well:
using umbraco.cms.helpers; using umbraco.BasePages;
So that is how you close and refresh a custom create dialog in your custom admin tree in Umbraco 4.5.2.
Feel free to ask questions in the comments.