title: How to remove google account from the android emulator?
body: <p>I want to remove my google account which I created on the emulator for Google APIs level 8 AVD.</p>
  
  <p>I tried removing it from <code>Settings -&gt; Accounts &amp; sync -&gt; Selecting account -&gt; Remove Account</code>, but I get this message,</p>
  
  <blockquote>
    <p>This account is required by some applications. You can only remove it by resetting the phone to factory defaults. You do that in the Settings application, under Privacy</p>
  </blockquote>
  
  <p>I tried doing it by resetting the phone to factory defaults by going to <code>Settings -&gt; Privacy -&gt; Factory data reset -&gt; Reset data -&gt; Erase everything</code>, and it shows a dialog of <code>Power Off</code> message, with indefinite progress bar and later the emulator gets stuck. Then, later, when I close and restart the emulator, the account doesn't get deleted.</p>
  
  <p>Also, I would like to know if it is possible to delete the account through code.</p>