Trolleule Posted January 28, 2013 Share Posted January 28, 2013 (edited) Hi peoplez,can someone help me to define the DLLCall for this function:BOOL WINAPI WIMGetMountedImageInfo( MOUNTED_IMAGE_INFO_LEVELS fInfoLevelId, PDWORD pdwImageCount, PVOID pMountInfo, DWORD cbMountInfoLength, PDWORD pcbReturnLength );Link: http://msdn.microsoft.com/en-us/library/windows/desktop/dd851928.aspxUsed DLL is wimgapi.dllI have tried this:; #STRUCTURE# =================================================================================================================== ; Name...........: $tagWIM_MOUNT_INFO_LEVEL1 ; Description ...: Contains information retrieved by the _WIM_GetMountedImageList function. ; Fields ........: WimPath - Specifies the full path to the .wim file. ; MountPath - Specifies the full path to the directory where the image is mounted. ; ImageIndex - Specifies the image index within the .wim file specified in WimPath. ; MountFlags - Specifies the current state of the mount point. ; | $WIM_MOUNT_FLAG_MOUNTED - The image is actively mounted. ; | $WIM_MOUNT_FLAG_MOUNTING - The image is in the process of mounting. ; | $WIM_MOUNT_FLAG_REMOUNTABLE - The image is not mounted, but is capable of being remounted. ; | $WIM_MOUNT_FLAG_INVALID - The image mount point is no longer valid. ; | $WIM_MOUNT_FLAG_NO_WIM - TThe WIM file backing the mount point is missing or inaccessible. ; | $WIM_MOUNT_FLAG_NO_MOUNTDIR - The image mount point has been removed or replaced. ; | $WIM_MOUNT_FLAG_MOUNTDIR_REPLACED - The mount point has been replaced with by a different mounted image. ; | $WIM_MOUNT_FLAG_READWRITE - The image has been mounted with read-write access. ; Author ........: Jonathan Holmgren (Homes32) ; Remarks .......: ; =============================================================================================================================== Global Const $tagWIM_MOUNT_INFO_LEVEL1 = "WCHAR WimPath[260];WCHAR MountPath[260];DWORD ImageIndex;DWORD MountFlags" Local $MOUNTED_IMAGE_INFO_LEVELS = DllStructCreate($tagWIM_MOUNT_INFO_LEVEL1) local $pdwImageCount = DllStructCreate("ptr") Local $pMountInfo = DllStructCreate("ptr") Local $pcbReturnLength = DllStructCreate("ptr") ;~ Local $cbMountInfoLength = DllStructCreate("int") ; Size of buffer in bytes Local $aResult2 = DllCall($ghwimgapi, "bool", "WIMGetMountedImageInfo", _ "ptr", DllStructGetPtr($MOUNTED_IMAGE_INFO_LEVELS), _ "ptr", DllStructGetPtr($pdwImageCount), _ ; [out] A pointer to a DWORD that receives the number of mounted images. "ptr", DllStructGetPtr($pMountInfo), _ ; [out opt] Pointer to a variable that receives the array of mounted image structures. The size of the information written varies depending on the type of structured defined by the fInfoLevelId parameter. "dword", DllStructGetSize($pMountInfo), _ ; [in] The size of the buffer pointed to by the pMountInfo parameter, in bytes. "ptr", DllStructGetPtr($pcbReturnLength)) ; [out] A pointer to a variable in which the function returns the size of the requested information.Has Someone an idea, how to get this function work please? Edited January 28, 2013 by Trolleule Link to comment Share on other sites More sharing options...
JohnOne Posted January 28, 2013 Share Posted January 28, 2013 Take a look here AutoIt Absolute Beginners Require a serial Pause Script Video Tutorials by Morthawt ipify Monkey's are, like, natures humans. Link to comment Share on other sites More sharing options...
Trolleule Posted January 29, 2013 Author Share Posted January 29, 2013 I work with this UDF and the author has not added this function Link to comment Share on other sites More sharing options...
hvandrie Posted January 13, 2015 Share Posted January 13, 2015 Trolleule, For whatever it's worth, I've written myself one... Link to comment Share on other sites More sharing options...
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