/// <summary>
        /// Shows this dialog with the provided view model.
        /// </summary>
        /// <param name="viewModel"></param>
        /// <returns></returns>
        public static bool?ShowDialog(NewScriptWizardDialogModel viewModel)
        {
            var dialog = new NewScriptWizardDialog();

            dialog.SetModel(viewModel);
            return(dialog.ShowModal());
        }
 void SetModel(NewScriptWizardDialogModel viewModel)
 {
     Host.DataContext   = viewModel;
     viewModel.Closing += OnModelClosing;
 }