Hi Niklas,
first of all I thank you for the prompt response. The ZahlenFormatID is
5107.
Regards,
Rudi
----- Original Message -----
From: "Niklas Nebel" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Wednesday, October 08, 2008 4:12 PM
Subject: Re: [api-dev] NumberFormats with decimals after the comma in
calc-table
On 10/ 8/08 03:04 PM, Rudolf Huber wrote:
I tried various options to get the correct declaration for NumberFormat
in calc. The LocalSetting.Language and Country is "de" for Germany.
In my table I get the value before the comma correctly, however, the
after comma values show zeros. Below, you see the code for the format:
ZahlenFormat = oTabellenDokument.NumberFormats
ZahlenFormatString = "##.##0,000"
ZahlenFormatId = ZahlenFormat.QueryKey(ZahlenFormatString,
LokaleEinstellungen, True)
If ZahlenFormatID = -1 Then
ZahlenFormatID = ZahlenFormat.addNew(ZahlenFormatString,
LokaleEinstellungen)
EndIf
The first "#" is unnecessary, but that shouldn't be a problem.
Do you apply the format to a cell? If so, what format code does the cell
format dialog show for that cell after running the macro?
Niklas
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]