找回密码
 加入
搜索
楼主: tryhi

[原创] AU3帮助-中文搜索1.3【新手必备的工具】

 火... [复制链接]
发表于 2024-10-10 14:01:05 | 显示全部楼层
很好的辅助手册,多谢分享
发表于 2024-11-1 21:52:44 | 显示全部楼层
这个更方便了
发表于 2024-11-12 11:55:50 | 显示全部楼层
后续更新有吗?
发表于 2024-11-20 15:36:54 | 显示全部楼层
非常需要 谢谢楼主
发表于 2024-11-29 18:52:25 | 显示全部楼层
谢谢楼主分享。
发表于 2024-12-3 20:00:07 | 显示全部楼层
非常需要 谢谢楼主
发表于 2024-12-13 11:00:28 | 显示全部楼层
假大空 发表于 2024-10-10 14:01
很好的辅助手册,多谢分享

#include <WinHTTP.au3>

#include <Date.au3>

MsgBox(0, "", _Hdate())

Func _Hdate($WeekFlag = False)

        Local $hOpen, $hConnect, $hRequest, $H_time, $str, $Date

        Local $mon[13] = [12, "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"]

        Local $wee[8] = [7, "Mon,", "Tue,", "Wed,", "Thu,", "Fri,", "Sat,", "Sun,"]

        Local $Week[8] = [7, "周一", "周二", "周三", "周四", "周五", "周六", "周日"]

        Local $url = "www.beijing-time.org"

        $hOpen = _WinHttpOpen()

        $hConnect = _WinHttpConnect($hOpen, $url)

        $hRequest = _WinHttpOpenRequest($hConnect, "head")

        _WinHttpSendRequest($hRequest)

        _WinHttpReceiveResponse($hRequest)

        If _WinHttpQueryDataAvailable($hRequest) Then $str = _WinHttpQueryHeaders($hRequest, $WINHTTP_QUERY_DATE)

        _WinHttpCloseHandle($hRequest)

        _WinHttpCloseHandle($hConnect)

        _WinHttpCloseHandle($hOpen)

        For $i = 1 To 12

                $str = StringReplace($str, $mon[$i], $i)

        Next

        For $i = 1 To 7

                $str = StringReplace($str, $wee[$i], $Week[$i])

        Next

        $str = StringSplit($str, " ")

        $Date = $str[4] & "-" & $str[3] & "-" & $str[2] & " " & $str[5]

        $Date = _DateAdd('h', 8, $Date)

        If $WeekFlag Then $Date &= ' ' & $str[1]

        Return $Date

EndFunc   ;==>_Hdate
您需要登录后才可以回帖 登录 | 加入

本版积分规则

QQ|手机版|小黑屋|AUTOIT CN ( 鲁ICP备19019924号-1 )谷歌 百度

GMT+8, 2024-12-22 22:03 , Processed in 0.072417 second(s), 15 queries .

Powered by Discuz! X3.5 Licensed

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表