Using this answer, I can create shortcuts (.lnk files) for various executables and folders.
When I use the Recent Items directory (C:\Users\%USERNAME%\AppData\Roaming\Microsoft\Windows\Recent) in the SHORTCUT, the PWS call creates the shortcut, but it disappears from File Explorer quickly - too quickly to register in an Open/Save dialog.
Strangely, the file still exists; I see it in the output of dir, and creating a new shortcut manually using these steps adds (2) to the file name used in the Shortcut tab of its Properties window. Similarly, creating the shortcut on the Desktop first, then copying it to the Recent Items folder, will prompt you for an overwrite. The copies disappear too, so this isn't a workaround either way.
How do I prevent the programmatic shortcuts from disappearing from the Recent Items folder?