lukevp / ESC-POS-.NET

Efficient, Easy to Use Thermal Printing & POS (Windows/Linux/OSX, WiFi/BT/USB/Ethernet)
MIT License
500 stars 161 forks source link

Epson USB printer - getting "System.IO.IOException: The handle is invalid" #248

Open ddevriend opened 8 months ago

ddevriend commented 8 months ago

I am using the newly released USB modules (USBPrinter.cs, DeviceDetails.cs, & DeviceFinder.cs) and using "net5.0-windows7.0 in my project files. Evthing seems to complie just fine, but when I run the Console Test, I get the following:

image

Any ideas?

ddevriend commented 8 months ago

I question the "The handle is invalid, " line. Does the "\?\" need to be formatted differently?

Gary-gr9 commented 7 months ago

I tested this using .net5.0-windows7.0, .net5.0, and .net6.0 with Epson printer but was unable to recreate the issue. Could you please provide me more information about the testing environment. Did you add these classes to the existing code? I'll give it a go and try fix the bug if it exists. Cheers