Files more than 260 characters in path length

I always try to avoid paths which are more than 255 characters long.

But in some specific cases they do inadvertently get created as e.g. when I backup a directory which has few files which are under the 260 character limit including path. When I back it up to some external drive and add root folders with date and/or machine name etc. the already long path names do get over the 260 character limit at that point of time. These are the files that cause the problem at a later date.

All said and done, finally I have to find all such files and take care of them individually to make it less than 260 or even better 240 characters.

Also I read that software which allow regular expressions to prefix path names, do allow to process the files when the \\?\ is used. However, I cannot figure out how to use \\?\ before the filename in path prefix. e.g. If I use E:\*.pdf with recursive to find all *.pdf files in E: , how do I use \\?\ instead of E:\. I am asking this as Directory Opus also allows regular expressions.

Thanks and Regards,