Пример #1
0
        private string print_header()
        {
            //string outstuff = "";

            //Print the store name, centered bold double size
            //string outstuff = "\x1B\x70\x40" + CRLF; //Open drawer

            string outstuff = ""; // OposPrinter.open_drawer(); //Open drawer

            StoreSettings store_settings = new StoreSettings(this.base_data.lokasi);

            outstuff += OposPrinter.align_center() + store_settings.get_store_name() + OposPrinter.CRLF;

            //Print address lines centered
            outstuff += OposPrinter.font0()
                        + OposPrinter.bold_off()
                        + OposPrinter.align_center() + store_settings.get_address1() + OposPrinter.CRLF
                        + store_settings.get_address2() + OposPrinter.CRLF + OposPrinter.CRLF;

            //Cashier and date/time
            outstuff += OposPrinter.align_left() + OposPrinter.font1()
                        + "Kasir:" + String.Format("{0,-21}", this.base_data.nmkas) + " " + String.Format("{0:dd MMM yyyy}", this.base_data.tgl) + OposPrinter.CRLF;
            //Transaction number
            outstuff += OposPrinter.underline() + "No: " + String.Format("{0,-35}", this.base_data.nobukti) + OposPrinter.CRLF;
            //Column headers
            outstuff += OposPrinter.underline_off() + "Qty " + "    Harga" + "     Disc           " + "Total" + OposPrinter.CRLF;
            //Thats all folks

            return(outstuff);
        }