So briefly - the big question is - where can i found the MonthCal_GetToday Macro to make it workes in my dllcall function
And in details, this is what i already tried.
I'm just trying to run this peace of code for the MonthCal_GetToday Macro , but the error level for my dllcall function return me -4 which means that The specified function could not be found inside the DLL.
So i tried the usual dll of windows : User32.dll, Kernel32.dll, ComCtl32.dll, or Gdi32.dll. - always returning me errorlever -4.
After this, i read a bit of msnd doc - and they said that the header is commctrl.h.
https://docs.microsoft.com/en-us/windows/win32/api/commctrl/nf-commctrl-monthcal_gettoday
I don't understand if i can use it as a dll in dllcall function ?
When i try to use it - dllcall returns me a function of -3. which means :
-3: The specified DllFile could not be accessed or loaded. If no explicit path was specified for DllFile, the file must exist in the system's PATH or A_WorkingDir. This error might also occur if the user lacks permission to access the file, or if AutoHotkey is 32-bit and the DLL is 64-bit or vice versa.
I tried to update a 64bit ahk version - i also tried to run as admin my actual script. I tried to copy my commctrl.h file into my actual directory (where my script is)
Nothing works.
Someone know what should i do ?
Here's my code below with all my fails :
Code: Select all
VarSetCapacity(DateDuJour, 16, 0)
DllCall("D:\Informatique\Logiciels\VisualStudioCSharp\Include\10.0.18362.0\um\CommCtrl.h\MonthCal_GetToday", "Ptr", &hwndOutPutVar, "Ptr", DateDuJour )
DllCall("CommCtrl.h\MonthCal_GetToday", "Ptr", &hwndOutPutVar, "Ptr", DateDuJour ) ; return -3
DllCall("User32\MonthCal_GetToday", "Ptr", &hwndOutPutVar, "Ptr", DateDuJour ) ; return -4
DllCall("ComCtl32\MonthCal_GetToday", "Ptr", &hwndOutPutVar, "Ptr", DateDuJour ) ; return -4
MsgBox %ErrorLevel%