本帖最后由 CCM 于 2012-11-21 17:32 编辑
请各位大侠过目
#include <GUIConstantsEx.au3>
Local $Button1, $msg
$Form1 = GUICreate("FTP連線工具", 288, 212, 235, 147)
$Label1 = GUICtrlCreateLabel("使用者名稱:", 16, 40, 92, 28)
$Input1 = GUICtrlCreateInput("", 120, 40, 145, 24)
$Label2 = GUICtrlCreateLabel("密碼:", 16, 80, 80, 28)
$Input2 = GUICtrlCreateInput("", 120, 80, 145, 24)
$Label3 = GUICtrlCreateLabel("FTP位置:", 16, 120, 92, 28)
$Input3 = GUICtrlCreateInput("請直接貼上網址", 120, 120, 145, 24)
$Button1 = GUICtrlCreateButton("連線", 168, 168, 65, 25)
GUISetState()
While 1
$msg = GUIGetMsg()
$username = GUICtrlRead($Input1) ;取得GUI INPUT 內容
$password = GUICtrlRead($Input2)
$address = GUICtrlRead($Input3)
$ftp = StringRegExp($address, "[^ftp://]+.", 3)
Select
Case $msg = $GUI_EVENT_CLOSE
ExitLoop
Case $msg = $Button1
ShellExecute("ftp://" & $username & ":" & $password & "@" & $ftp)
EndSelect
WEnd
ShellExecute("ftp://" & $username & ":" & $password & "@" & $ftp) 这样错误
ShellExecute("ftp://" & $username & ":" & $password & "@" & $address)这样正确
请问我那边出了错? |