如何在C#中使用OPOS在Bixion 350III中打印阿拉伯语

时间:2016-12-18 15:24:07

标签: c# forms opos

阿拉伯语打印按钮的代码

 private void btnPrintArabic_Click(object sender, EventArgs e)
    {

//Just For Display in List
        AddList("+Print Arabic");


        var source = "على";

        var westernLatin = Encoding.GetEncoding(1256);
        var arabic = Encoding.GetEncoding(1256);

        var bytes = arabic.GetBytes(source);
        var result = westernLatin.GetString(bytes); // Uáì
        Printer.MapCharacterSet = true;
        Printer.CharacterSet = 864;

        int nRC = Printer.PrintNormal(2, result);
        AddList("Print Arabic = " + nRC);
        AddList("-Print Arabic " + ((nRC == (int)OPOS_Constants.OPOS_SUCCESS) ? "Succeeded" : "Failed"));
    }

我在做什么都有任何错误。我尝试了很长时间的结果,但即使在堆栈中也没有正确的答案。打印机打开和关闭以及正常打印工作正常。当涉及到其他语言时它不起作用< / p>

我尝试过多次参考,但无法打印阿拉伯语

Other Option By Khalid

其他结果参考

Other Option By Khalid

Bixilon的Opos手册参考

http://bixolon.com/upload/download/manual_bxl%20sdk%20for%20ios_upos%20compliant%20api%20reference%20guide_english_rev_1_03.pdf

0 个答案:

没有答案