我正在为项目开发热敏收据打印机(ARP-990KE),我尝试使用以下代码打印发票,但在代码中GetDevice()
给我错误值不能为空。参数名称:设备
PosExplorer posExplorer = new PosExplorer(this);
DeviceInfo receiptPrinterDevice = posExplorer.GetDevice("Generic/Text Only");
return (PosPrinter)posExplorer.CreateInstance(receiptPrinterDevice); // Here it gives me null