VBA to Clear Negative Values with Negative Exponent

jski21

Board Regular
Joined
Jan 2, 2019
Messages
155
Office Version
  1. 2016
Platform
  1. Windows
Good morning Mr. Excel Team,

I think I have an unusual request. I work for a large governmental organization. I've made great strides in getting their data management and reporting up to speed. One issue I've come across is there is frequently large negative numbers in the data sets. The cell shows "0.00" however, if you select the cell, you can see the negative number carried out to 8, 9, sometimes 10 decimal places along with a negative exponent. An example would be -6.40284270048142E-10. I'm working towards getting this cleared up (easier said than done in a large govt. org.), but for all intents and purposes, I treat this field truly as 0 for analysis and reporting purposes. I find myself sorting the often large datasets from smallest to largest and copying/pasting all zero values with a true 0. Has anyone run across this?

My request is does anyone have/seen VBA code that would search for these values in a dataset and convert them to zero?

Thanks in advance for your advice and insight on this rather strange issue.


jski
 

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.

Forum statistics

Threads
1,223,912
Messages
6,175,340
Members
452,638
Latest member
Oluwabukunmi

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