ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Format of amount in label (https://www.excelbanter.com/excel-programming/379716-format-amount-label.html)

Gert-Jan[_3_]

Format of amount in label
 
Hi,

This doesn't work:

Label1.Caption = "? " & Round(Range("sheets1!G46").Value, 2, NumberFormat =
"0.00")

I want the label to show a text like ? 93,44 in stead of 93,44231. Can
someone help?

Thanks in advance, Gert-Jan




Gert-Jan[_3_]

Format of amount in label
 
Found it:

Label1.Caption = Format(Range("sheets1!G46").Value, "? #,##0.00")

"Gert-Jan" schreef in bericht
...
Hi,

This doesn't work:

Label1.Caption = "? " & Round(Range("sheets1!G46").Value, 2, NumberFormat
= "0.00")

I want the label to show a text like ? 93,44 in stead of 93,44231. Can
someone help?

Thanks in advance, Gert-Jan







Stevek

Format of amount in label
 
ActiveSheet.Label1.Caption = "? " & Round(Range("sheet1!g46"),2)
seems to work for me.

"Gert-Jan" wrote in message
...
Hi,

This doesn't work:

Label1.Caption = "? " & Round(Range("sheets1!G46").Value, 2, NumberFormat
= "0.00")

I want the label to show a text like ? 93,44 in stead of 93,44231. Can
someone help?

Thanks in advance, Gert-Jan







All times are GMT +1. The time now is 10:04 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com