How to show that two timestamps are identical?

JenniferMurphy

Well-known Member
Joined
Jul 23, 2011
Messages
2,525
Office Version
  1. 365
Platform
  1. Windows
One column of a table contains timestamps (date + time). Here is an example:

R/CAB
18/04/18 08:10p8/04/18 08:10p
28/05/18 06:47p8/05/18 06:47p
38/06/18 07:35a8/06/18 07:35a
48/06/18 06:03p8/06/18 06:03p
58/06/18 06:03p=
68/07/18 06:55p8/07/18 06:55p
78/07/18 06:55p=
88/07/18 06:55p=
98/08/18 08:46a8/08/18 08:46a
108/09/18 09:30a8/09/18 09:30a

<tbody>
</tbody>


A5 is identical to A4 and both A7 & A8 are identical to A6. I would like to display the data in Col A as it is in Col B. Is that possible without changing the actual underlying values?

I would prefer not to have a second column just for the display, as above.
 

Excel Facts

Create a Pivot Table on a Map
If your data has zip codes, postal codes, or city names, select the data and use Insert, 3D Map. (Found to right of chart icons).
Not sure how you can have a cell taking two different values i.e. the original date/time at some point being replaced by an '='. Surely you will lose the date/time as it is effectively overwritten? You could append the '=' on to the end of the date/time string and then change the font colour of the date/time bit to white. This would however place the '=' at the right hand edge of the cell - unless you alter the size of the date/time string to very small which would move the '=' over to the left a bit nearer the middle. You might then need to strip off the '=' from the date/time string depending on your requirements.
 
Upvote 0
If col A is numerical values, rather than text, then you could use CF
 
Last edited:
Upvote 0
Not sure how you can have a cell taking two different values i.e. the original date/time at some point being replaced by an '='. Surely you will lose the date/time as it is effectively overwritten? . . .

The cell wouldn't have two different values. I'm not trying to design a qubit. It would just display a different value. This is already possible with Excel's conditional data formatting sections.

Consider this example:
  • Col C has the values.
  • Col D has the exact same values, as shown in Col E, but formatted with this conditional formatting string: [<1]"too small";[>99]"too large";0.00.
  • Col F has the same values as Col E plus "1", which clearly shows that the underlying value is still usable in arithmetic.

R/CCDEFG
511.00D5: =C52.00F5: =D5+1
60.99too smallD6: =C61.99F6: =D6+1
79999.00D7: =C7100.00F7: =D7+1
899.01too largeD8: =C8100.01F8: =D8+1

<tbody>
</tbody>

I was hoping for something like that but with a comparison to a different cell.
 
Upvote 0
If col A is numerical values, rather than text, then you could use CF
If you mean conditional formatting, I couldn't get it to work.

In D17 of this table,

R/CCD
1255
1377
1477
1533

<tbody>
</tbody>
I tried
Code:
[=D13]"=";general
but Excel changed it to
Code:
[=0]"=";General
Do you know a different way?
 
Upvote 0
In CF > New Rule > use a formula > =COUNTIF(A$6:A6,A6)>1 > for format use "=" > OK
 
Upvote 0
In CF > New Rule > use a formula > =COUNTIF(A$6:A6,A6)>1 > for format use "=" > OK

Aha -- that CF. :)

I have never been able to get that to work. I always end up with multiple "rules", many conflicting with each other. I'll give it another try.

Thanks
 
Upvote 0
With the formula the A$6 needs to be the first cell in the applies to range
 
Upvote 0
With the formula the A$6 needs to be the first cell in the applies to range

Yeah, I know, but for some reason it has never worked for me. I think part of the problem is that I tend to reorganize the tables, so the ranges grow and shrink and the rules don't keep up -- possibly because I code them wrong. One time I literally ended up with something like 40-50 rules. Part of the problem is that there are multiple ranges and I like to copy one range to start another one.

Anyway, I'll give it another try. :oops:
 
Upvote 0
@JenniferMurphy


A simple way to prove it works... follow EXACTLY...

Add a NEW worksheet (NO HISTORIC MESS!)
This formula in cell A2 and copy to A3 and A4
=NOW()
This formula in A5 and copy to A6 and A7
=NOW()+2
This formula In A8 copy to A9 and A10
=NOW()+3

Select A2:A10
Click on conditional formatting \ New Rule \ Use formula ....
Enter this formula
=A1=A2
Click on grey Format button \ Number \ Custom \ under "Type" enter = (the equals sign that you want displayed)

It looks EXACTLY like you wanted column A to look
 
Last edited:
Upvote 0

Forum statistics

Threads
1,214,523
Messages
6,120,047
Members
448,940
Latest member
mdusw

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