you can try this . It will work.
        
fd = (EditText) findViewById(R.id.from_date);
td = (EditText) findViewById(R.id.to_date);
int MILLIS_IN_DAY = 1000 * 60 * 60 * 24;
                        Date date = new Date();
                        SimpleDateFormat dateFormat = new 
SimpleDateFormat("dd/MM/yyyy");
                        String frommdate = dateFormat.format(date.getTime());
                        String nextDate = dateFormat.format(date.getTime() - 7
                                        * (MILLIS_IN_DAY));
                        fd.setText(nextDate);
                        td.setText(frommdate);

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to