UrlDownloadToFile, ftp://rrsyycmc:mima2015@103.59.146.107:0/domains/tv.rrsyycm.com/public_html/autohotkey/download/ cy.txt, d:cy.txt if ErrorLevel = 0 { MsgBox,恭喜 }
测试
#Persistent #SingleInstance force UrlDownloadToFile,http://ofakkjnzz.bkt.clouddn.com/Habit.zip,1.zip MsgBox % ErrorLevel Return /* F2:: HKL:=DllCall("LoadKeyboardLayout", Str,00000804, UInt, 1) ControlGetFocus,ctl,A SendMessage,0x50,0,HKL,%ctl%,A ime:=HabitFUN.默认输入法.中文1英文0 ptrSize := !A_PtrSize ? 4 : A_PtrSize VarSetCapacity(stGTI, cbSize:=4+4+(PtrSize*6)+16, 0) NumPut(cbSize, stGTI, 0, "UInt") ; DWORD cbSize; DllCall("GetGUIThreadInfo", Uint,0, Uint,&stGTI) hwnd := NumGet(stGTI,8+PtrSize,"UInt") DllCall("SendMessage", "UInt", DllCall("imm32ImmGetDefaultIMEWnd", "UInt", HWND), "UInt", 0x0283, "Int", 0x006, "Int", 0) Return /* conn:= ComObjCreate("ADODB.connection") conn.Open("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=e:OneDriveAHKProgram_list.mdb") rs := conn.OpenSchema(20) t := [] rs.MoveFirst() while !rs.EOF { t_name := rs.("TABLE_NAME").value MsgBox % t_name try { q := conn.Execute("select top 1 * from [" t_name "]") t[t_name] := [] for field in q.Fields ;获取按顺序排列的字段 t[t_name].insert(field.Name) q.close() } rs.MoveNext() }