Renderer Posted May 22, 2016 Posted May 22, 2016 (edited) Hello guys ! When i want to call a DLL function, i get a sort of error.The error i receive is captured in the image bellow. Error.bmp Here i have the code example: DllCall('user32.dll','int','CloseDesktop') if @error Then MsgBox(18,'',@error) EndIf Edited May 22, 2016 by Renderer
AutoBert Posted May 22, 2016 Posted May 22, 2016 (edited) after refrehing FF seeing unneccary answer. Edited May 22, 2016 by AutoBert
Developers Jos Posted May 22, 2016 Developers Posted May 22, 2016 Looks like you need to provide a pointer to the desktop to close. Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
Danyfirex Posted May 22, 2016 Posted May 22, 2016 Look msdn. BOOL WINAPI CloseDesktop( _In_ HDESK hDesktop ); Regards Danysys.com AutoIt... UDFs: VirusTotal API 2.0 UDF - libZPlay UDF - Apps: Guitar Tab Tester - VirusTotal Hash Checker Examples: Text-to-Speech ISpVoice Interface - Get installed applications - Enable/Disable Network connection PrintHookProc - WINTRUST - Mute Microphone Level - Get Connected NetWorks - Create NetWork Connection ShortCut
RTFC Posted May 23, 2016 Posted May 23, 2016 (edited) If the aim is just to close a desktop, you don't need to use dllcall directly, as _WinAPI_CloseDesktop() already provides a wrapped call for that. See my SecondDesktop UDF (link in my sig) for an example. More generally, a tutorial on using dllcall is here; you may also wish to check this out. Edited May 23, 2016 by RTFC My Contributions and Wrappers Spoiler BitMaskSudokuSolver BuildPartitionTable CodeCrypter CodeScanner DigitalDisplay Eigen4AutoIt FAT Suite HighMem MetaCodeFileLibrary OSgrid Pool RdRand SecondDesktop SimulatedAnnealing Xbase I/O
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now