Hi!

I need use a Bluetooth Printer (DATECS DPP-250).

But, I'm having a serious problems...

I using te folowing code:


BluetoothAdapter bth = BluetoothAdapter.DefaultAdapter;

if (!bth.IsEnabled)
bth.Enable();

ICollection bthD = bth.BondedDevices;

foreach (BluetoothDevice d in bthD)
{
if (d.Name == "DPP-250")
{
Java.Util.UUID UUID =
Java.Util.UUID.FromString("00001101-0000-1000-8000-00805F9B34FB");

// Get the BLuetoothDevice object
BluetoothSocket s = d.CreateRfcommSocketToServiceRecord(UUID);
s.Connect();

byte[] buffer = System.Text.Encoding.GetEncoding(0).GetBytes("Teste");

RunOnUiThread(delegate
{
IAsyncResult xpto = s.OutputStream.BeginWrite(buffer, 0, buffer.Length, new
AsyncCallback(delegate { }), State.On);
s.Close();
}
}

And don't work.

Some helpe?



--
View this message in context: 
http://mono-for-android.1047100.n5.nabble.com/Print-using-DPP-250-tp5711660.html
Sent from the Mono for Android mailing list archive at Nabble.com.
_______________________________________________
Monodroid mailing list
[email protected]

UNSUBSCRIBE INFORMATION:
http://lists.ximian.com/mailman/listinfo/monodroid

Reply via email to