Thread: Anonomise data
View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Martin Fishlock[_4_] Martin Fishlock[_4_] is offline
external usenet poster
 
Posts: 32
Default Anonomise data

Try the following function:

Public Function CleanDate(d As Date) As Date
CleanDate = DateSerial(1975, 4 + Year(d) - 1975, 1)
End Function

--
HTHs Martin


"Wicked Wizard" wrote:

I have a spreadsheet in XL2000 containing some data extracted from a DB. I
need to make the data anonymous so I can use it for training purposes. In
the date of birth column I want to change the dates so that
anyday/anymonth/1975 becomes 01/04/1975, anyday/anymonth/1976 becomes
01/05/1975, and so on.

My initial idea was a case statement applied to every cell in the column -
but I can't make it work.

Any assistance would be gratefully received.

WW