ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Custom number format (https://www.excelbanter.com/excel-programming/413812-custom-number-format.html)

ScoobyDoo[_2_]

Custom number format
 
This is driving me crazy..

I have a column with data that looks like this:

2Dec5255

It is not a date but EXCEL treats it like a date,. When I enter the
value into an excel
cell it shows up as 2-Dec-55.

The code I am currently use is

Columns("B:B").Select
Selection.NumberFormat = "ddmmmyy"

I need a custom number format that I can put in to display the numbers
correectly.

Thanks

Dave Peterson

Custom number format
 
columns("B:B").numberformat = "@" 'text



ScoobyDoo wrote:

This is driving me crazy..

I have a column with data that looks like this:

2Dec5255

It is not a date but EXCEL treats it like a date,. When I enter the
value into an excel
cell it shows up as 2-Dec-55.

The code I am currently use is

Columns("B:B").Select
Selection.NumberFormat = "ddmmmyy"

I need a custom number format that I can put in to display the numbers
correectly.

Thanks


--

Dave Peterson


All times are GMT +1. The time now is 04:34 PM.

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