I use Python, but I think the same problem exists in C #.
I would like to be able to support extended paths (paths with len> 260, which are represented as //? / C: / blah / blah). It seems like the standard way to move files to the trash is SHFileOperationW or SHFileOperation.
In python, the useful xplatform library, move2trash, uses SHFileOperationW. Several articles in C # say to use the same thing.
The problem with SHFileOperationW is that it does not support extended paths. This is a common limitation of SH tools.
Does anyone have any tricks for working with the cart and advanced paths?
Links Links: Version C # , the Python version
source
share