BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 06-15-2011, 02:39 AM   #1 (permalink)
Thumbs Must Hurt
 
Join Date: Mar 2011
Model: 8900
PIN: N/A
Carrier: Torch
Posts: 59
Post Thanks: 3
Thanked 1 Time in 1 Post
Default TimeZone Offset

Please Login to Remove!

I calculated time zone offset but it gives me zero

TimeZone tz= TimeZone.getTimeZone("Countryname/Cityname");
Calendar c=Calendar.getInstance();
c.setTimeZone(tz);
c.setTime(new Date());
int ofst=tz.getOffset(1, c.get(Calendar.YEAR), c.get(Calendar.MONTH), c.get(Calendar.DAY_OF_MONTH), c.get(Calendar.DAY_OF_WEEK), c.get(Calendar.MILLISECOND));


What is wrong with above code . why it gives me zero?
Offline  
Closed Thread


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads for: TimeZone Offset
Thread Thread Starter Forum Replies Last Post
TrackIt TimeZone world clock and network time sync Kirkx Aftermarket Software 1 09-17-2009 07:34 AM
Hoe to change the Server Timezone in simulator samuels007 Developer Forum 0 04-01-2009 02:00 AM
phpberrystats blubyu BES Admin Corner 107 01-07-2009 11:27 AM
Offline capability and TimeZone vashwin Developer Forum 0 11-08-2007 01:48 PM
7100g and timezone tintin_bb General Legacy Device Discussion 2 05-08-2007 08:50 AM

FLSH-YUYCX0022SQRTBLBLUEGG-Flash Furniture YU-YCX-002-2-SQR-TBL-BLUE-GG 24-Inch
$77.39
FLSH-YUYCX0022SQRTBLBLUEGG-Flash Furniture YU-YCX-002-2-SQR-TBL-BLUE-GG 24-Inch pictureFLSH-YT1872MELWALGG-Flash Furniture 18 by 72" Rectangular Mahogany Melamine Lam
$84.72
FLSH-YT1872MELWALGG-Flash Furniture 18 by 72FLSH-YT1872HIGHWALGG-Flash Furniture 18 by 72" Rectangular High Pressure Mahoga
$93.24
FLSH-YT1872HIGHWALGG-Flash Furniture 18 by 72FLSH-XUDG697BLADCLRBARWALWGG-Flash Furniture Hercules Series Clear Coated Ladde
$83.76
FLSH-XUDG697BLADCLRBARWALWGG-Flash Furniture Hercules Series Clear Coated Ladde pictureFLSH-XUDG694BLADCLRWALWGG-Flash Furniture Hercules Series Clear Coated Ladder B
$67.0
FLSH-XUDG694BLADCLRWALWGG-Flash Furniture Hercules Series Clear Coated Ladder B picture






Copyright 2004-2016 BlackBerryForums.com.
The names RIM and BlackBerry are registered Trademarks of BlackBerry Inc.