I have a problem that I have not been able to solve, with the printing with Android 5, I am using a Bluetooth POS printer, it does not always print, many times it does not find the printer or it finds it but it does not establish connection, other times it does not print the complete ticket.
Meanwhile I have a phone with android 8, this prints always, without failing.
I think it should be a problem with Android 5 because with different devices with Android 5 the same thing happens.
Meanwhile I have a phone with android 8, this prints always, without failing.
I think it should be a problem with Android 5 because with different devices with Android 5 the same thing happens.
B4X:
Printer.Initialize2(BTConnection.OutputStream,"windows-1252")
Printer.WriteLine(Chr(27)&"t"&Chr(16))
Printer.WriteLine(" SOCIEDAD FORESTAL M4 LTDA.")
Printer.WriteLine(" ")
Printer.WriteLine("PATENTE : "& PATENTE_PRT)
Printer.WriteLine("TARA : "& ModConn.nf.Format(TARA_PRT))
Printer.WriteLine("CARGA : "& ModConn.nf.Format(CARGA_PRT))
Printer.WriteLine("TOTAL : "& ModConn.nf.Format(TOTAL_PRT))
Printer.WriteLine("FECHA : "& FECHA_PRT)
Printer.WriteLine(" ")
Printer.WriteLine("DESPACHADOR : "& DESPACHADOR_PRT)
Printer.WriteLine("N° GUÍA : "& NGUIA_PRT)
Printer.WriteLine(" ")
Printer.WriteLine("Sr. Conductor revise su guía y")
Printer.WriteLine("que tenga un buen viaje.")
Printer.WriteLine(" ")
Printer.WriteLine(" www.avlchile.cl")
Printer.WriteLine(" ")
Printer.WriteLine(" ")
Printer.WriteLine(" ")
Sleep(2000)
Printer.Flush
Printer.Close