Custom format cell to consider dash as zero in excel

adpatel

New Member
Joined
May 30, 2019
Messages
42
Office Version
  1. 2016
Platform
  1. Windows
I import data from web external query in excel in which zero value represented as dash, to further calculation on this I need to consider this dash as zero
for that I have macro to convert dash to zero but, data gets refreshed every 5 min. so I need to run that replacement macro every 5 min.
instead of this I want to do is,apply format cell in which dash will be considered as zero and I will import data by selecting preserve format, so no need to run replacement macro every 5 min.
So pls let me know custom format cell in which positive value ll be consider as positive,negative as negative but dashes as zero
thank you.
 

Excel Facts

How to change case of text in Excel?
Use =UPPER() for upper case, =LOWER() for lower case, and =PROPER() for proper case. PROPER won't capitalize second c in Mccartney
A custom format does not change the underlying value in the cell. So if the dash is causing a calculation problem, custom formatting won't help.
Perhaps if you tell us about the "further calculation", that can possibly be modified to treat the dashes as zero without actually changing them.
 
Upvote 0
OK, I got your point.
I am 1st coping this data to another range and then I use the copied data and new refreshed data for comparision
 
Upvote 0
So how do the dashes impact on that comparison?

Perhaps you could show us a small set of dummy sample data that shows 'current' & 'previous' data and how you want them compared?
 
Upvote 0

Forum statistics

Threads
1,223,231
Messages
6,170,884
Members
452,364
Latest member
springate

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