Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello!
How I can format a number with a text Range("A2") .NumberFormat = "[$-2000000]#0,000.00" If I want " this number is 2000" then something like Range("A2") ="This number is " & format(2000, "[$-2000000]#0,000.00") Thanks |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
maybe something like
Range("A2").NumberFormat = """this number is ""$#,##0.0" columns(1).Autofit -- Regards, Tom Ogilvy "Abdul" wrote: Hello! How I can format a number with a text Range("A2") .NumberFormat = "[$-2000000]#0,000.00" If I want " this number is 2000" then something like Range("A2") ="This number is " & format(2000, "[$-2000000]#0,000.00") Thanks |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks tTom,
It wont work when I say Range("A2") .NumberFormat = "[$-2000000]#0,000.00" Then the number I input in A2 will be changing to Hindi (Arabic(Saudi Arabia)) format I want add some text to A2 using code with a number and the number should be in Hindi(Arabic-saudi arabia) format Thanks On Mar 13, 3:25 pm, Tom Ogilvy wrote: maybe something like Range("A2").NumberFormat = """this number is ""$#,##0.0" columns(1).Autofit -- Regards, Tom Ogilvy "Abdul" wrote: Hello! How I can format a number with a text Range("A2") .NumberFormat = "[$-2000000]#0,000.00" If I want " this number is 2000" then something like Range("A2") ="This number is " & format(2000, "[$-2000000]#0,000.00") Thanks |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Sub ABC()
Range("A2").NumberFormat = _ "\T\h\i\s\ \n\u\m\b\e\r\ \i\s\ [$-2000000]#0,000.00" End Sub worked for me. If you want the text string to be in Saudi/Arabic as well, then I can't say. -- Regards, Tom Ogilvy "Abdul" wrote: Thanks tTom, It wont work when I say Range("A2") .NumberFormat = "[$-2000000]#0,000.00" Then the number I input in A2 will be changing to Hindi (Arabic(Saudi Arabia)) format I want add some text to A2 using code with a number and the number should be in Hindi(Arabic-saudi arabia) format Thanks On Mar 13, 3:25 pm, Tom Ogilvy wrote: maybe something like Range("A2").NumberFormat = """this number is ""$#,##0.0" columns(1).Autofit -- Regards, Tom Ogilvy "Abdul" wrote: Hello! How I can format a number with a text Range("A2") .NumberFormat = "[$-2000000]#0,000.00" If I want " this number is 2000" then something like Range("A2") ="This number is " & format(2000, "[$-2000000]#0,000.00") Thanks |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks
How I can Add a text and number using code? A1 is empty now. I want to add "This number is 2000" in A1 thru VBA and the number tobe formated in Hindi ([$-2000000]#0,000.00") Thanks On Mar 13, 6:08 pm, Tom Ogilvy wrote: Sub ABC() Range("A2").NumberFormat = _ "\T\h\i\s\ \n\u\m\b\e\r\ \i\s\ [$-2000000]#0,000.00" End Sub worked for me. If you want the text string to be in Saudi/Arabic as well, then I can't say. -- Regards, Tom Ogilvy "Abdul" wrote: Thanks tTom, It wont work when I say Range("A2") .NumberFormat = "[$-2000000]#0,000.00" Then the number I input in A2 will be changing to Hindi (Arabic(Saudi Arabia)) format I want add some text to A2 using code with a number and the number should be in Hindi(Arabic-saudi arabia) format Thanks On Mar 13, 3:25 pm, Tom Ogilvy wrote: maybe something like Range("A2").NumberFormat = """this number is ""$#,##0.0" columns(1).Autofit -- Regards, Tom Ogilvy "Abdul" wrote: Hello! How I can format a number with a text Range("A2") .NumberFormat = "[$-2000000]#0,000.00" If I want " this number is 2000" then something like Range("A2") ="This number is " & format(2000, "[$-2000000]#0,000.00") Thanks |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
A1 could be a formula ="This number is " & TEXT(A2,yourformat).
An equivalent VBA statement would be Range("A1") = "This number is " & FORMAT(Range("A2"),yourformat). Carl On Mar 14, 4:18 am, "Abdul" wrote: Thanks How I can Add a text and number using code? A1 is empty now. I want to add "This number is 2000" in A1 thru VBA and the number tobe formated in Hindi ([$-2000000]#0,000.00") Thanks On Mar 13, 6:08 pm, Tom Ogilvy wrote: Sub ABC() Range("A2").NumberFormat = _ "\T\h\i\s\ \n\u\m\b\e\r\ \i\s\ [$-2000000]#0,000.00" End Sub worked for me. If you want the text string to be in Saudi/Arabic as well, then I can't say. -- Regards, Tom Ogilvy "Abdul" wrote: Thanks tTom, It wont work when I say Range("A2") .NumberFormat = "[$-2000000]#0,000.00" Then the number I input in A2 will be changing to Hindi (Arabic(Saudi Arabia)) format I want add some text to A2 using code with a number and the number should be in Hindi(Arabic-saudi arabia) format Thanks On Mar 13, 3:25 pm, Tom Ogilvy wrote: maybe something like Range("A2").NumberFormat = """this number is ""$#,##0.0" columns(1).Autofit -- Regards, Tom Ogilvy "Abdul" wrote: Hello! How I can format a number with a text Range("A2") .NumberFormat = "[$-2000000]#0,000.00" If I want " this number is 2000" then something like Range("A2") ="This number is " & format(2000, "[$-2000000]#0,000.00") Thanks- Hide quoted text - - Show quoted text - |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Convert number to arabic(Hindi) format with text | Excel Programming | |||
Convert number to arabic(Hindi) format with text | Excel Programming | |||
How do I get Arabic numbers converted to English text format? | Excel Worksheet Functions | |||
Convert arabic number to english text | Excel Discussion (Misc queries) | |||
converting an arabic number into a spellout text | Excel Worksheet Functions |