LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 279
Default Curious general format rounding

I am running some VBA in Excel 2003.
I have a couple of cells. Each has General format and is empty.
I write "1.5" to both.
In one case the cell is bold and the value is rendered as "2".
If I remove bold, the value is rendered as "1.5".
In the other, the cell is not bold and the value is rendered as 1.5.

Ah ha. It is a question of room to fit the value.

Let me see if I can construct a simple macro to show the behavior.

In a new workbook, step through the following code:
Columns("A:A").ColumnWidth = 1 ' Make [A1] narrow
ActiveCell = "1.5" ' [A1] is rendered as "2"
Columns("A:A").ColumnWidth = 3 ' [A1] is rendered as "1.5"

I would appreciate a pointer to appropriate documentation.

Later!
It is documented in <http://support.microsoft.com/kb/182197
Now I understand what is happening, I can adjust to it.
--
Walter Briscoe
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel is defaulting to Number format instead of General format Kim Excel Discussion (Misc queries) 1 March 11th 10 01:25 PM
Format: General - Text - General iturnrocks Excel Worksheet Functions 3 August 11th 06 04:47 PM
excel numbers in general format i cant add cant change format claude Excel Worksheet Functions 2 July 7th 06 08:18 PM
VBA automatically change text format into general format? Nicawette Excel Programming 2 June 13th 06 01:35 PM
Curious Worksheet Format PT New Users to Excel 1 December 9th 04 07:23 AM


All times are GMT +1. The time now is 02:10 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"