adding a hidden apostrophe to a cell

H

hedgracer

I need to use a function to add a hidden apostrophe to a cell. For
example, the cell has 2021 and needs to have '2021 with the ' hidden.
Does anyone know a function that can do that? Any help is appreciated.
Thanks.

Dave
 
F

FSt1

hi
if you only have one then you can use the find and replace to do that
Ctrl+F > replace tab
Replace what: 2021
Replace with: '2021
click replace button

if you have a lot, then you would be looking a macro.

Regards
FSt1
 
S

Sandy Mann

Select the range with the cells that you want to change then run this Macro:

Sub AddIt()
For Each cell In Selection
cell.Value = "'" & cell.Value
Next cell
End Sub

--
HTH

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings

(e-mail address removed)
Replace @mailinator.com with @tiscali.co.uk
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top