Open cliffzhu opened 1 year ago
I get the same error - I can see that it's the pnputil that is making the mess.
@cliffzhu did you come though with a working method?
In the Install-Printer.ps1 I modified the $INFARGS to add quotes around the file path. This allows spaces to be used when referencing the .inf file.
Original version:
$INFARGS = @( "/add-driver" "$INFFile" )
My version:
$INFARGS = @( "/add-driver " + '"' + $INFFILE + '"' )
It may be a sloppy way of doing it, but it seems to work.
Install-Printer.ps1 refuse to run when inf file in a subfolder's name with a space.