Re: How to Initiate Logoff Sequence with RDP Protocol using 11.52 (136 Views)
Reply
Regular Advisor
BAC Man
Posts: 131
Registered: ‎05-14-2003
Message 1 of 2 (151 Views)

How to Initiate Logoff Sequence with RDP Protocol using 11.52

Using RDP Protocol with LR 11.52. Script connects OK to a Windows 2008 server. However, using a keyboard sequence to initiate logoff is not working. Anyone know why? Below is the code I am using to initiate the logoff:

 

 

rdp_key("StepDescription=Key Press 4", 
        "Snapshot=snapshot_6.inf", 
        "KeyValue=VK_END", 
        "KeyModifier=CONTROL_KEY,ALT_KEY", 
        RDP_LAST);
    
    lr_think_time(5);
    
    rdp_key("StepDescription=Key Press 5", 
        "Snapshot=snapshot_7.inf", 
        "KeyValue=VK_DOWN", 
        RDP_LAST);
    
    rdp_key("StepDescription=Logoff", 
        "Snapshot=snapshot_logoff.inf", 
        "KeyValue=VK_RETURN", 
        RDP_LAST);

Please use plain text.
Regular Visitor
manasvi123
Posts: 1
Registered: ‎12-08-2011
Message 2 of 2 (136 Views)

Re: How to Initiate Logoff Sequence with RDP Protocol using 11.52

Can you try to use the following keystrokes to execute the Logoff from remote machine:

 One thing i observed in your code is - there is no wait/think time while using the keyboard strokes for  "KeyValue=VK_LEFT", and   "KeyValue=VK_RETURN". Try to introduce wait/think time between them and it should work.

 

*********************************************************************************************

 

Also, I can suggest from the steps which i am using in scripts for Log-off from remote machine

Use Key Stroke - Control+Escape  - and than navigate to the LogOff tab on Start Menu followed by Enter Key. Also, introduce the function after the above steps - rdp_sync_on_server_disconnect

 

 

Let me know how it goes with you. Share your experience.

 

Thanks

Manasvi Rajan

Please use plain text.
The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation