Jump to content

Benchozer

Members
  • Posts

    1
  • Joined

  • Last visited

Benchozer's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. Hi everybody, I need to resize the "Rdp embedded sessions" in order to resize $oRDP in the same size without borders Anybody can help me ? Thanks I have the following code : #include <GUIConstantsEx.au3> #include <WinAPI.au3> #include <WindowsConstants.au3> $host = "" ;<<<<<<< enter here the host name or ip address $hGUI = GUICreate("Terminal server", 900, 700, -1, -1, BitOR($GUI_SS_DEFAULT_GUI,$WS_SIZEBOX,$WS_THICKFRAME)) $oRDP = ObjCreate("MsTscAx.MsTscAx.2") $oRDP_Ctrl = GUICtrlCreateObj($oRDP, 0, 0, 900, 700) GUICtrlSetResizing(-1, $GUI_DOCKLEFT+$GUI_DOCKRIGHT+$GUI_DOCKTOP+$GUI_DOCKBOTTOM+$GUI_DOCKWIDTH+$GUI_DOCKHEIGHT) GUICtrlSetStyle($oRDP_Ctrl , $WS_VISIBLE) s$oRDP.DesktopWidth = 900 $oRDP.DesktopHeight = 700 $oRDP.Fullscreen = False $oRDP.ColorDepth = 16 $oRDP.AdvancedSettings3.SmartSizing = True $oRDP.Server = $host $oRDP.UserName = "" ;<<<<<<< enter here the user name $oRDP.Domain = "" $oRDP.AdvancedSettings2.ClearTextPassword = "" $oRDP.ConnectingText = "Connecting to " & $host $oRDP.DisconnectedText = "Disconnected from " & $host $oRDP.StartConnected = True $oRDP.Connect() GUISetState(@SW_SHOW, $hGUI) $oShel = ObjCreate("shell.application") $oShel_Ctrl = GUICtrlCreateObj($oShel, 0, 0, 900, 700) GUICtrlSetStyle($oShel_Ctrl , $WS_VISIBLE) Send("#r") Send ("C:\Program Files (x86)\scripts\PSTools\******.bat") Send("{ENTER}") While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE $oRDP.Disconnect() Exit EndSwitch WEnd
×
×
  • Create New...