How to? if isdir ....

#3
Appears to be Kernel32.dll, GetFileAttributesW(). And FILE_ATTRIBUTE_DIRECTORY is 16 (0x10).
You could get misleading results if you specify the name of something that doesn't exist. GetFileAttributesW will return -1 (0xFFFFFFFF). If you test that result like this
Code:
if %@eval[%@winapi[...] AND 16] == 16, it will be true.
 
Oct 18, 2008
265
1
#4
You could get misleading results if you specify the name of something that doesn't exist. GetFileAttributesW will return -1 (0xFFFFFFFF). If you test that result like this
Code:
if %@eval[%@winapi[...] AND 16] == 16, it will be true.
Hello –

Thanks for the info –

I been using sugarsync and just updated to V2 ... I have app that using that call (GetFileAttributes) too, but when I test to see if the item specified is a dir in the new SS drive, it fails where the tcc “if isdir” works –

there is info in the doc for the win api func to test for 0xffff – which means the item does not exist

call you post the text to the winapi call – thx