MartinK said:Whoops, I am looking forward to learn something new then![]()
Anyway, I am curious to see if someone comes up with an idea for custom format...
Cheers
Martin
Private Sub Worksheet_Change(ByVal Target As Range)
Dim c
If Target.Cells.Count = 1 Then
If Target.Value >= 1000000 Then
Target.Cells.NumberFormat = "0"",""00"",""000.00"
Else
Target.Cells.NumberFormat = "##,###.00"
End If
Else
For Each c In Target
If c.Value >= 1000000 Then
c.Cells.NumberFormat = "0"",""00"",""000.00"
Else
c.Cells.NumberFormat = "##,###.00"
End If
Next c
End If
End Sub
Hi pbchhaya:pbchhaya said:default cell format is like 100,000 now i would like to show my no. as 1,00,000 or if numirc with 2 dgt then 1,00,000.00. I am unable to do so. can any one help.
pbchhaya
Book2 | ||||||
---|---|---|---|---|---|---|
B | C | D | E | |||
1 | Number | Numberofupto15digits formatedforIndiasystemofpresentation | ||||
2 | 1000000000 | 1,00,00,00,000 | ||||
3 | 1000 | 1,000 | ||||
4 | 10000 | 10,000 | ||||
5 | 100000 | 1,00,000 | ||||
Sheet4 (2) |
y040131h1a.xls | ||||||
---|---|---|---|---|---|---|
B | C | D | E | |||
1 | Number | Numberofupto15digits textformatedforIndiasystem ofpresentation | coercingtextformated backtotruenumber | |||
2 | 1000000000 | 1,00,00,00,000 | 1000000000 | |||
3 | 1000 | 1,000 | 1000 | |||
4 | 10000 | 10,000 | 10000 | |||
5 | 100000 | 1,00,000 | 100000 | |||
Sheet4 (2) |