Turn on or off Your remote session will be disconnected RDC prompt

On your Windows 11/10 PC, you can run the mstsc.exe command or use the Microsoft Remote Desktop app to connect to and control your Windows PC from a remote location on a remote device. With remote desktop connection, you can use another device to connect to your PC and have access to all of your apps, files, and network resources as if you were physically present at your home desk; and for easy and quick access, you can create Remote Desktop Connection shortcut. By default, when you close a Remote Desktop Connection (RDC) window, you will receive a prompt with the message Your remote session will be disconnected – this dialog allows you to confirm your action of ending the active session. PC users can turn on or off displaying the confirmation message for your account when closing a Remote Desktop Connection window in either of two ways – in any case, keep in mind:

You must be signed in as an administrator.You must enable Remote Desktop on a PC.You can also use Remote Desktop (RDP) in Windows 11/10 Home; so, for Home edition users, you need to follow the instructions as provided in this linked post.

1] Enable or Disable Your remote session will be disconnected RDC prompt via the Dialog

The quickest way to turn off displaying the confirmation message, is to check the Don’t display this message again box, and click/tap on OK. In subsequent connections, when you try to disconnect, the dialog won’t pop up again for that particular remote machine.

2] Turn On or Off Your remote session will be disconnected RDC prompt via Registry Editor

To turn On or Off Your remote session will be disconnected RDC prompt via Registry Editor in Windows 11/10, do the following: Since this is a registry operation, it is recommended that you back up the registry or create a system restore point as necessary precautionary measures. Once done, you can proceed as follows:

Press Windows key + R to invoke the Run dialog.In the Run dialog box, type regedit and hit Enter to open Registry Editor.Navigate or jump to the registry key path below:

At the location, on the right pane, right-click on the blank space on the right pane and then select New > DWORD (32-bit) Value to create a registry key and then rename the key as ShowShutdownDialog and hit Enter.Double-click on the new entry to edit its properties.Input 1 (On) or 0 (Off) in the Value data field per your requirement.Click OK or hit Enter to save the change.Exit Registry Editor.Restart your PC.

Alternatively, you can automatically turn on or enable the ShowShutdownDialog in the registry. Here’s how:

Press Windows key + R to invoke the Run dialog.In the Run dialog box, type notepad and hit Enter to open Notepad.Copy and paste the code below into the text editor.

Now, click the File option from the menu and select Save As button.Choose a location (preferably desktop) where you want to save the file.Enter a name with .reg extension (eg; TurnOnSSD.reg).Choose All Files from the Save as type drop-down list.Double-click the saved .reg file to merge it.If prompted, click on Run > Yes (UAC) > Yes > OK to approve the merge.You can now delete the .reg file if you like.Restart PC.

Likewise, you can automatically disable or turn off the key – simply follow the steps above, but this time, copy and paste the code below and save the reg file as TurnOffSSD.reg. That’s it! TIP: If Windows Remote Desktop disconnects frequently or automatically, you can fix the issue by following the linked post.

How do I fix a Disconnected remote session?

To fix a disconnected remote session will largely depend on what caused the disconnection. The following solutions can be applied:

Deleting the MSLicensing Key.Deleting the GracePeriod Key.Run RDP as an Administrator.Restart Remote Desktop Services.

How do you fix Remote session was disconnected because there are no remote desktop license servers available?

To fix Remote session was disconnected because there are no remote desktop license servers available, you can try the following fix amongst others:

Open Registry Editor (regedit).Go to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server\RCM.Export this registry key to a file before making any changes.Locate the GracePeriod key and either delete or rename it.Reboot the RDSH server.

How do I keep my Remote session active?

You can enable the Configure keep-alive connection interval policy via Local Group Policy Editor in the the following location Computer Configuration > Administrative Templates > Windows Components > Remote Desktop Services > Remote Desktop Session Host > Connections. If you enable this policy, you must enter a keep-alive interval.