Skip to content Skip to sidebar Skip to footer

Get The Upload Progress

My upload method as below: private void upload(String Server, String FilePath, String SavePath, String NewName) { String end = '\r\n'; String twoHyphens = '--'; String boundary = '

Solution 1:

You can try following code,

First display a Progress Dialog Before calling your upload method,

progDailog = ProgressDialog.show(loginAct,"Process ", "please wait....",true,true);

newThread ( newRunnable()
{
     publicvoidrun()
     {
      // your uploading code goes here
     }
}).start();

 Handler progressHandler = newHandler() 
 {

     publicvoidhandleMessage(Message msg1) 
     {

         progDailog.dismiss();
         }
 }

Post a Comment for "Get The Upload Progress"