Find Value

R2

New Member
Joined
Oct 8, 2002
Messages
5
How to find or search a value that display 2 decimal places(e.g $525.97) but in reality has more than 2 decimal numbers(e.g.$525.96578)?

Ctrl + F don't work.

Thank you for the help.
 

Excel Facts

Quick Sum
Select a range of cells. The total appears in bottom right of Excel screen. Right-click total to add Max, Min, Count, Average.
Hi,

because ,256 changes in ,26 you should use ,2 and not ,26. Don't know if that's accurate enough.

Geert
 
Upvote 0
Try this code

Set rng = Range("A1:A10")

For Each c In rng
If c.NumberFormat = "0.00" Then
sNumberString = Str(c.Value)
If InStr(1, sNumberString, ".") Then
nLength = Len(sNumberString)
If (nLength - InStr(1, sNumberString, ".") > 2) Then
'At this point the cell is formated to 2 decimal places
'but the number is more than this
'
'Do what you want here!
End If
End If
End If
Next
 
Upvote 0

Forum statistics

Threads
1,214,653
Messages
6,120,749
Members
448,989
Latest member
mariah3

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