iam trying to call URLDownloadToFile function with callback currently callback is not firing
this is my code plz help
#include <AutoItConstants.au3>
#include <MsgBoxConstants.au3>
#include <GUIConstantsEx.au3>
; Create Stub
;$hStub = _DllCallBack ("_OnProgress", "Hwnd;ulong;ulong:str")
Local $hHandle = DllCallbackRegister("_OnProgress", "int", "long;long;long;str")
; Script Start - Add your code below here
Global Const $DOWNLOAD_URL_1 = "https://google.com"
DownloadFile($DOWNLOAD_URL_1,"D:\abc.html")
Func DownloadFile($url,$filename)
DllCall("urlmon.dll", "long", "URLDownloadToFile", "ptr", "none", "str", $url, "str", $filename, "dword", 0, "Ptr", DllCallbackGetPtr($hHandle))
MsgBox($MB_SYSTEMMODAL, "", "download Complete " & @error)
EndFunc
; Callback Procedure
Func _OnProgress($ulProgress, $ulProgressMax,$ulStatusCode,$wszStatusText)
MsgBox($MB_SYSTEMMODAL, "", "Success2")
return 1
;
EndFunc ;==>_EnumWindowsProc
DllCallbackFree($hHandle)