2

i'm using long path names with UNC (UNI), for example:

 \\?\c:\tmp......\file1.prn

but when i try to send the file to a printer on windows command-line, for example with copy/print command, it shows :
for copy -

0 file(s) copied.

for print -

invalid switch

the regular path / shortened (using ~) works well, its only the UNC large (>260 chars) that does not work.

Michael Hampton
  • 237,123
  • 42
  • 477
  • 940
gadh
  • 21
  • 2

1 Answers1

0

Not sure if this works for your case, but sometimes I have gotten over limitations of long UNC paths by mapping them to network drives and then using them as if they were local drives.

Im sure there’s a cleaner way, but unless the operation requires drives to really be drives and folders to be local folders, this trick might work as well.

Alpha
  • 151
  • 1
  • 4