Researcher

Researcher

  • 1.7k
  • 23
  • 686

RDP Viewer Blank When Host is Minimized

Apr 29 2021 5:08 AM
I am using Windows Remote Assistance to Access remote pc. Whenever the Shared screen on Source(Host) side is minimized the Client(Viewer) will have blank screen. Both Host and Viewer in Windows server 2012 r2 .
 
I have also tried below .NET code for remote share.
 
Host code:
  1. namespace ScrS_server_ {  
  2.   public partial class Form1: Form {  
  3.     RDPSession x = new RDPSession();  
  4.     private void Incoming(object Guest) {  
  5.       IRDPSRAPIAttendee MyGuest = (IRDPSRAPIAttendee) Guest; //???   
  6.       MyGuest.ControlLevel = CTRL_LEVEL.CTRL_LEVEL_INTERACTIVE;  
  7.     }  
  8.     private void button1_Click(object sender, EventArgs e) {  
  9.       x.OnAttendeeConnected += Incoming;  
  10.       x.Open();  
  11.     }  
  12.     private void button2_Click(object sender, EventArgs e) {  
  13.       IRDPSRAPIInvitation Invitation = x.Invitations.CreateInvitation("Trial""MyGroup""", 10);  
  14.       textBox1.Text = Invitation.ConnectionString;  
  15.     }  
  16.     private void button3_Click(object sender, EventArgs e) {  
  17.       x.Close();  
  18.       x = null;  
  19.     }  
  20.   }  
  21. }  
Viewer code:
  1. namespace ScrS_viewer_ {  
  2.   public partial class Form1: Form {  
  3.     private void button1_Click(object sender, EventArgs e) {  
  4.       string Invitation = textBox1.Text; // "";//   
  5.       Interaction.InputBox("Insert Invitation ConnectionString""Attention");  
  6.       axRDPViewer1.Connect(Invitation, "User1""");  
  7.     }  
  8.     private void button2_Click(object sender, EventArgs e) {  
  9.       axRDPViewer1.Disconnect();  
  10.     }  
  11.     private void Form1_Load(object sender, EventArgs e) {  
  12.       panel1.Height = Screen.PrimaryScreen.Bounds.Height - 100;  
  13.     }  
  14.   }  
  15. }  
Code reference :https://www.c-sharpcorner.com/uploadfile/ulricht/how-to-create-a-simple-screen-sharing-application-in-C-Sharp/
 
Even this have same issue, but error occurs randomly.
 
I have tried :
 
1.Registry changes mentioned in this link (https://sahipro.com/docs/faq/remote-desktop-connection.html),but it didn't help.
2.Tried Run as admin didn't help
 
How to solve this issue?

Answers (2)