Search code examples
windowswinapintfs

How to create files that delete other files on Windows?


When I save a web page from Google Chrome, I get a HTML file and a directory with the resources. When I send one of them to the Recycle Bin, the other tags along as if they are linked by the file system. Here's an example:

enter image description here

What is this facility called and how do you create these links via Win32 system calls? It's not a hard link as this doesn't point to the same file. When I use del from a Command Prompt, it only deletes the one file, so it must be something Explorer is doing.


Solution

  • I can create an HTML file named foo.html and a directory named foo_files and Explorer will pair these. It only will work with .html or .htm files.

    Thanks to Remy.