update textview in oncreate android
<p>hi frnds i have a button and a textview in a whole view,when i click the button then all contact are sved in csv file but i wnt when these contact  are going to csv file it update text as "exporting 3 (this count is changingmeans 1 2 3 4 5....till total no of contacts) contcts " means text view is changing when i click button then how to do it</p>

<p>the code for getting total no. of contacts in phone is below...</p>

<pre><code>      update:



                    @Override
        protected Boolean doInBackground(String... args) {
            int count;
            CSVWriter writer = null;
          try 
           {
            writer = new CSVWriter(new FileWriter(Environment.getExternalStorageDirectory().getAbsolutePath() + "/my_test_contact.csv"));
        } catch (IOException e1) {
            // TODO Auto-generated catch block
            e1.printStackTrace();
         }
        String displayName;
        String number;
        String emailid;
        long _id;

        String columns[] = new String[]{ ContactsContract.Contacts._ID,
                   ContactsContract.Contacts.DISPLAY_NAME };
        writer.writeColumnNames(); // Write column header
        Cursor cursor = getContentResolver().query(ContactsContract.Contacts.CONTENT_URI,
                   columns,                
                   null,               
                   null,               
                   ContactsContract.Data.DISPLAY_NAME + " COLLATE LOCALIZED ASC");
        startManagingCursor(cursor);
         if(cursor.moveToFirst()) {  
           do {
               _id =      Long.parseLong(cursor.getString(cursor.getColumnIndex(ContactsContract.Contacts._ID)));   
               displayName = cursor.getString(cursor.getColumnIndex(ContactsContract.Contacts.DISPLAY_NAME)).trim();
               number = getPrimaryNumber(_id);
               emailid=getEmailid(_id);


               writer.writeNext((displayName + "/" + number+ "/" +  emailid).split("/"));
           } 
           while(cursor.moveToNext());   
           csv_status = true;
       } else {
           csv_status = false;
       }
       try {
            if(writer != null)
                writer.close();
        } catch (IOException e)
        {
           Log.w("Test", e.toString());
        }
    return null;

     }
</code></pre>
