title: Date from EditText
body: <p>I try to get date from edittext in Android, but code return wrong text.</p>
  
  <p>Java code:</p>
  
  <pre><code>SimpleDateFormat df = new SimpleDateFormat("dd-MM-YYYY"); 
  java.util.Date myDate;
  myDate = df.parse(editText1.getText().toString());
  String myText = myDate.getDay() + "-" + myDate.getMonth() + "-" + myDate.getYear() + "abcd";
  </code></pre>
  
  <p>XML code:</p>
  
  <pre><code>&lt;EditText
                  android:id="@+id/editText1"
                  android:layout_width="match_parent"
                  android:layout_height="wrap_content"
                  android:ems="10"
                  android:inputType="date"&gt;
  </code></pre>
  
  <p>When I write text "23-08-2013" in EditText, code return "5-7-113-abcd". What is wrong? How can I get correct date from EditText?</p>