3
我安裝了Bixolon BCD-1000 OPOS Driver.It可以打印ASCII字符,但是我必須打印西里爾文字符。當我嘗試將CharacterSet 437(默認字符集)更改爲999(UNICODE)時,它會返回錯誤消息。 [故障信息] [1]Microsoft POS C#CharacterSet屬性無法設置。
public void DisplayStringOnPort(string line)
{
PosExplorer posExplorer = new PosExplorer();
DeviceInfo receiptPrinterDevice = posExplorer.GetDevices()[0];
var list = posExplorer.GetDevices();
foreach(DeviceInfo x in list)
{
if(x.ServiceObjectName.Equals("BCD-1000"))
{
receiptPrinterDevice = x;
}
}
LineDisplay printer = posExplorer.CreateInstance(receiptPrinterDevice) as LineDisplay;
printer.Open();
printer.Claim(1000);
string str = "Кирилица";
printer.CharacterSet = 999; // Unicode Fault Message
printer.DeviceEnabled = true;
printer.DisplayTextAt(2, 1, text);
printer.Close();
}
我該如何克服這種情況? 謝謝
非常好的問題:P – albatross