#SingleInstance Force fPath = C:\WINDOWS\Help\clipbrd.chm ; Путь для XP URL := "mk:@MSITStore:" fPath "::/whatis_intro_cb.htm" req := ComObjCreate("Msxml2.XMLHTTP.6.0") req.open("GET", URL, 0) req.send ResponseText := req.responseText req := "" ResponseText := Ansi2UTF8(ResponseText) MsgBox, % RegExReplace(ResponseText, "s).*?<title>(.*)?</title>.*", "$1") Ansi2UTF8(sString) { Ansi2Unicode(sString, wString, 0) Unicode2Ansi(wString, zString, 65001) Return zString } Ansi2Unicode(ByRef sString, ByRef wString, CP = 0) { nSize := DllCall("MultiByteToWideChar" , "Uint", CP , "Uint", 0 , "Uint", &sString , "int", -1 , "Uint", 0 , "int", 0) VarSetCapacity(wString, nSize * 2) DllCall("MultiByteToWideChar" , "Uint", CP , "Uint", 0 , "Uint", &sString , "int", -1 , "Uint", &wString , "int", nSize) } Unicode2Ansi(ByRef wString, ByRef sString, CP = 0) { nSize := DllCall("WideCharToMultiByte" , "Uint", CP , "Uint", 0 , "Uint", &wString , "int", -1 , "Uint", 0 , "int", 0 , "Uint", 0 , "Uint", 0) VarSetCapacity(sString, nSize) DllCall("WideCharToMultiByte" , "Uint", CP , "Uint", 0 , "Uint", &wString , "int", -1 , "str", sString , "int", nSize , "Uint", 0 , "Uint", 0) } |