Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default rToRange.value = rFromRange.value = always "rounds" the value.....help?

Hello all,
I have some pretty simple code that is trying to move the "value" from
one range to another.....each range happens to be a single cell. Each
cell has been formatted in the worksheets to be number format
$#,##0.000000 (i.e. six decimals - yes I am dealing with fractions of a
penny)......
Now lets say the value in the rFromRange is equal to $3.235765, I then
(in code) set the value of the rToRange to be equal to the value in the
rFromRange.....but what I end up with in the rToRange is $3.240000.....
I have tried EVERYTHING....I have even tried getting the number format
from the "from" range and applying it to the "to" range....but to no
avail.....the number in the result ends up always being rounded to 2
decimals....and I am beginning to pull my hair out......

Anyone any ideas?

Code is pretty straight forward (I have simplified this a bit - but the
basics are there...)

Dim rFromRange as Range, rToRange as Range
set rToRange as Range("whereitsgoing")
set rFromRange as Range("whereitsfrom")
rToRange.Value = rFromRange.value

Please help
Thanks,
Monkman.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default rToRange.value = rFromRange.value = always "rounds" the value.....help?


If they are always single values, can you dim them as single or double
data types?

Regards
Mike


--
Mikeopolo
------------------------------------------------------------------------
Mikeopolo's Profile: http://www.excelforum.com/member.php...o&userid=18570
View this thread: http://www.excelforum.com/showthread...hreadid=546949

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default rToRange.value = rFromRange.value = always "rounds" the value.....help?

Not quite sure what you mean by that?
I have at one point tried to get the value out of the range and put it
into a single (and a double) and then put that value into the
destination range - but still I get the same result......
Still Lost.....

Reply
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 - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell Steve Kay Excel Discussion (Misc queries) 2 August 8th 08 01:54 AM
change "true" and "false" to "availble" and "out of stock" inthestands Excel Worksheet Functions 2 July 19th 07 07:05 PM
HELP on "left","right","find","len","substitute" functions serene83 Excel Discussion (Misc queries) 5 June 27th 06 02:23 AM
Count occurences of "1"/"0" (or"TRUE"/"FALSE") in a row w. conditions in the next BCB New Users to Excel 7 May 13th 06 10:02 PM
If changed array formula reduce ""\""\""\ - signs to #Missing, will it make ... Maria J-son[_2_] Excel Programming 2 March 5th 06 12:20 PM


All times are GMT +1. The time now is 07:17 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"