| Reply | « Previous Thread | Next Thread » |
|
Why does the same program behave in different ways on 6680 (first screenshot) and 6600 (second?!?)
http://trafficlc.googlecode.com/files/6680.jpg http://trafficlc.googlecode.com/files/6600.jpg Source is: Code:
Calendar myCalender = Calendar.getInstance (TimeZone.getTimeZone ("UTC"));
Date d = new Date (myCalender.getTime ().getTime () + (0*60*60*1000));
LastUpdate = d.toString();
|
|
Hi cassioli,
the Date.ToString() has not been implemented in the 6600 vm... Take a look at this thread: http://discussion.forum.nokia.com/fo...ad.php?t=90440 Regards, Marco. |
|
Quote:
This is my implementation: Code:
Calendar myCalender = Calendar.getInstance (TimeZone.getTimeZone ("UTC"));
int year = myCalender.get(Calendar.YEAR);
int month = myCalender.get(Calendar.MONTH)+1;
int day = myCalender.get(Calendar.DATE);
int hour = myCalender.get(Calendar.HOUR_OF_DAY);
int min = myCalender.get(Calendar.DATE);
LastUpdate = Integer.toString(year)+"/"+
Lead0(month)+"/"+
Lead0(day)+" "+
Lead0(hour)+":"+
Lead0(min);
public String Lead0(int number) {
if (number<10) return "0"+Integer.toString(number); else return Integer.toString(number);
}
|
| Reply | « Previous Thread | Next Thread » |
| Thread Tools | Search this Thread |
|---|---|
| Thread | Thread Starter | Forum | Replies | Last Post |
|---|---|---|---|---|
| Python S60 Emulator | NAYSAMBO | Python | 25 | 2009-04-08 11:22 |
| Infra-red capability | Symbian_Challenge_0412 | General Discussion | 1 | 2005-08-16 19:24 |