To set up a PowerShell script that opens a dialog box and immediately closes it while allowing the PowerShell window to remain open (and also closeable via the top right corner), you can make use of Windows Forms in PowerShell.
Here's a basic example of how to implement that in a PowerShell script:
```powershell
# Load the necessary assembly to use Windows Forms
Add-Type -AssemblyName System.Windows.Forms
# Create a function to show the dialog


