Take a look at this site:
http://www.mcgimpsey.com/excel/udfs/unixtoxltime.html
Hope this helps.
Pete
On Sep 24, 4:41*pm, Roy <praish1...@yahoo.com> wrote:
> Hi All,
>
> I have a field on my excel report which comes as a UnixTime
> (1235502582).I want this to be in Excel readable format for e.g 24-
> SEP-2009 21:20.The char is string type
>
> I want to use this in a macro,since affer the data is downloaded,i
> want the code to convert.The data is several thousand rows.How would I
> make a column reference to call the macro.
>
> If I am using a macro like ,
>
> Public Function UnixTime2DT(lUnixTimeStamp As Long) As Date
> * UnixTime2DT = DateAdd("s", lUnixTimeStamp, #1/1/1970#)
> End Function
> *how would i call it to a particular column?
>
> I tried to call it as .Column("A").NumberFormat = UnixTime2DT ,but it
> did not work
> *or if I am using this formula,how would I use it in a macro?
> (UnixTime/86400) + 25569
>
> Thanks,
>
> Roy