title: How to Attach FIles Through Mail in android
body: <p>hi first of all i want to say an using gmail sender To send mails on a button click in my app  where i got <a href="https://stackoverflow.com/questions/2020088/sending-email-in-android-using-javamail-api-without-using-the-default-android-a">Solution From Here</a> </p>
  
  <p>now in the above code i cant attach files .but later i have seen a solution from Stack over flow to solve this in that there was some modification done in the "GMailSender.java" file the modified  link is <a href="https://stackoverflow.com/questions/6005983/sending-email-with-attachment-through-gmailsender?answertab=oldest#tab-top">Here</a></p>
  
  <p>how ever there is Addition portion to attach file now my problem is that i don't understand the modified portion. <strong>here is the old portion</strong> </p>
  
  <blockquote>
    <p>public synchronized void sendMail(String subject, String body, String sender, String recipients)</p>
  </blockquote>
  
  <p><strong>the modified portion is</strong> </p>
  
  <blockquote>
    <p>public synchronized void sendMail(String subject, String body, String sender, String recipients, File attachment)</p>
  </blockquote>
  
  <p>this is not a duplicated question i just want to know What this "File attachment" portion is and what type or method should i implement to attach a file  if you have any doubt please go through these Two links and  please find the solution thanks in advance</p>