title: Creating a dialog for Word Addin
body: <p>How can I create a Settings dialog for a Word Addin. </p>
  
  <p>I have already creating a <code>Windows Form</code> and I'm calling 'form.Show()`. But It's creating a new Window. </p>
  
  <p>How can I pass the owner by <code>form.ShowDialog(owner)</code>?</p>
  
  <p>I've solve my question creating a Helper for open the Dialog, but I don't know if is the best way</p>
  
  <pre><code>public static DialogResult ShowDialog(Form dialog)
  {
      NativeWindow mainWindow = new NativeWindow();
      mainWindow.AssignHandle(Process.GetCurrentProcess().MainWindowHandle);
      DialogResult dialogResult = dialog.ShowDialog(mainWindow);
      mainWindow.ReleaseHandle();
      return dialogResult;
  }
  </code></pre>