Hey Guys,I'm having some problems while trying to send a big file (2MB) through RFCOMM. My application hangs before go away sending it.. It seems it hangs on this line but I'm not pretty sure:
desire curFile=0; byte[] byteArray; while (curFile<size){ frmEnvio setTitle("Enviando arquivo"); if ((size-curFile)<=1024){ byteArray = new byte[(int)(size-curFile)]; dis read(byteArray,0,byteArray length); curFile+=size-curFile; create write(byteArray,0,byteArray length); output flush(); barraProgresso setValue((int)(curFile)); Thread sleep(10); }else{ byteArray = new byte[1024]; dis construe(byteArray,0,1024); curFile+=1024; output create verbally(byteArray,0,byteArray length); output flush(); barraProgresso setValue((int)(curFile)); Thread sleep(10); } }
Forex Groups - Tips on Trading
Related article:
http://developer.sonyericsson.com/thread.jspa?threadID=41807
comments | Add comment | Report as Spam
|