Автор: euheny
Дата сообщения: 28.09.2007 00:11
ViSiToR
а так :
Код: [no]If $CmdLine[0] = 4 Then
If $CmdLine[1] = "dial-up" Then
$tit1 = "Connect dial-up"
$tit2 = "Network Connections"
Run(@ComSpec & ' /c start "" ' & "rasphone.exe", "", @SW_HIDE)
WinWait($tit2, "", 5)
ControlCommand($tit2, "", "Button1", "Check", "Button")
WinWait($tit1, "", 5)
ControlFocus($tit1, "", "Edit1")
ControlSend($tit1, "", "Edit1", "{DEL 11}")
ControlCommand($tit1, "", "Edit1", "EditPaste", $CmdLine[3])
ControlCommand($tit1, "", "Edit2", "EditPaste", $CmdLine[4])
ControlFocus($tit1, "", "Edit3")
ControlSend($tit1, "", "Edit3", "{DEL 11}")
ControlCommand($tit1, "", "Edit3", "EditPaste", $CmdLine[2])
ControlCommand($tit1, "", "Button4", "Check", "Button")
WinWait($tit2, "", 5)
ControlCommand($tit2, "", "Button2", "Check", "Button")
EndIf
EndIf
[/no]