|
Post by George on Jul 26, 2021 15:10:23 GMT -5
They look just fine to me Robert. BUT . . . . They don't work. I added SPF_TRACE(ON) and it shows the SHELL coming back with RC=0. Will investigate further. OK, simple error, I have files in paths that have embedded spaces. So FName needs to be wrapped in $DQ Attached are corrections with the 1 line change George RO.Macro (345 B) RW.macro (345 B)
|
|
|
Post by George on Jul 27, 2021 9:37:30 GMT -5
Robert: Not sure why it picks on Favorites, but it is inconsistent. Played around and here's what I believe is happening. The macro is issuing the SHELL command with ASYNCH. So SPFLite continues on while Windows does the ATTRIB change. In some cases it is doing the refresh before the ATTRIB has completed. So I changed it to SYNCH, but that made it worse, it hung waiting for the SYNCH to complete.  ? So I switched it from HIDDEN to NORMAL and I could see the command window sitting waiting for an EXIT command. Next - off to the SPF_SHELL code. Turns out it's invoking the CMD processor with a /K operand, which means 'keep the window open'. So that's why it never returned. So I altered SHELL to use /K for ASYNCH and /C for SYNCH and it seems fine now. Here's my final RW/RW macros and the corrected SPFLite. George RO.Macro (344 B) RW.macro (344 B) SPFLite25.exe (512 KB)
|
|
|
Post by George on Jul 27, 2021 13:51:35 GMT -5
And I was surprised by that quirk of SYNCH/ASYNCH and the incorrect /K /C operand. Glad it turned up and got corrected.
George
|
|