BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 02-14-2007, 02:03 AM   #1 (permalink)
New Member
 
Join Date: Jan 2007
Model: 8700G
Posts: 9
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default Newbie Formating problems

Please Login to Remove!

Hi Im having problems with the following code:

MessageFormat mf = new MessageFormat("{0,number,$#,###.##}"); // Error ocurrs here
Object[] objs = {new Double(i)};
return mf.format( objs ).toString();

I based my code on java.text.MessageFormat as the API documentation describes

help... somebody ?

thanks in advance

rudolf
Offline  
Old 02-14-2007, 08:19 PM   #2 (permalink)
Knows Where the Search Button Is
 
Join Date: Nov 2006
Model: 7250
Carrier: Carrier Has Arrived
Posts: 29
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

you may want to go to BlackBerry API to use

net.rim.device.api.i18n.MessageFormat

access blackberry api by going to your BlackBerry JDE.
------
Click Help menu
-> Click API Reference
OR
------
Just press (SHIFT + F1) shortcut
Offline  
Old 02-14-2007, 08:22 PM   #3 (permalink)
New Member
 
Join Date: Jan 2007
Model: 8700G
Posts: 9
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

thanks.

But actually I based my code on the JDE, BB API Reference... thats why im confused.
Offline  
Old 02-14-2007, 08:44 PM   #4 (permalink)
Knows Where the Search Button Is
 
Join Date: Nov 2006
Model: 7250
Carrier: Carrier Has Arrived
Posts: 29
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default

i dont see a method prototype like the one you are using

try this method..
format(Object arguments, StringBuffer result, FieldPosition ignored)
Retrieves formatted string representation of argument list.


---------
by the way, i can compile your code okay..
try importing that library..

import net.rim.device.api.i18n.MessageFormat;

Last edited by newToThis : 02-14-2007 at 08:53 PM.
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

1PC USED Siemens 840D axis card 6SN1118-0DH21-0AA1 6SN1 118-0DH21-0AA1 #ZL02
$1558.6
1PC USED Siemens 840D axis card 6SN1118-0DH21-0AA1 6SN1 118-0DH21-0AA1 #ZL02 picture1PC Siemens 6SE7 400-1TA11-0AA0 6SE7400-1TA11-0AA0 #ZL02
$1266.0
1PC Siemens 6SE7 400-1TA11-0AA0 6SE7400-1TA11-0AA0 #ZL02 pictureSiemens Contactor 40 Amp, 3 Pole, 208 / 240 V. Coil, 42CF35AG, 50 Amp Resistive
$29.77
Siemens Contactor 40 Amp, 3 Pole, 208 / 240 V. Coil, 42CF35AG, 50 Amp Resistive picture1PC USED Siemens 6SE7028-0EA87-2DA0 6SE7 028-0EA87-2DA0 #ZL02
$973.98
1PC USED Siemens 6SE7028-0EA87-2DA0 6SE7 028-0EA87-2DA0 #ZL02 picture1PC NEW IN BOX SIEMENS 3RK1301-0AB13-1AA2 3RK1301-0AB13-1AA2 #ZL02
$1389.99
1PC NEW IN BOX SIEMENS 3RK1301-0AB13-1AA2 3RK1301-0AB13-1AA2 #ZL02 picture






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