Avoiding Floating Point

Boris7265

Board Regular
Joined
Apr 6, 2011
Messages
68
Hello,<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p>
<o:p></o:p>
I have transferring data from one spreadsheet onto another via macro and the floating point is changing datas on the spreadsheet where data have been transferring. Please, how can I avoid the floating point?<o:p></o:p>
The data should be imported on the spreadsheet without changing due we submit it to clients (large <?xml:namespace prefix = st1 ns = "urn:schemas-microsoft-com:office:smarttags" /><st1:place w:st="on"><st1:country-region w:st="on">usa</st1:country-region></st1:place> banks is this case).The data that have been changed. For examples, all data in column c consist 17 digits and it is like 6011004975859139 (reference numbers) and this number has been transferred onto another spreadsheet as 6.011E+15 that is different number to the first spreadsheet.
<o:p> </o:p>
Any help will be greatly appreciated.<o:p></o:p>
<o:p> </o:p>
Thank you,<o:p></o:p>
<o:p> </o:p>
The Best Regards <o:p></o:p>
<o:p> </o:p>
 

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.
This isn't a problem with floating point precision.

It's a limitation of Excel that it can't/won't calculate more than 15 digits.
Any digit beyond 15 is changed to a 0


Resolution is to keep the values as TEXT, not numbers.
 
Upvote 0
Thank you very much Jonmo1.

Ok, I didn't know that . I have tried to declare the variable as the string , but I have had the same result .
I am not very knowledge in vb code, would you be so kind to give me some hint or peace of code how can I copy -paste column c to another spreadsheet avoiding the floating point or some advice

Thank you very much in advance.

The Best Regards.
 
Upvote 0
A basic copy/paste should retain the text formatting of the cells.


Can you post the code you're currently using?
 
Upvote 0

Forum statistics

Threads
1,224,613
Messages
6,179,894
Members
452,948
Latest member
Dupuhini

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top