# How to Decipher TIMESTAMP Field in .PJX Files

ID: Q119226

The information in this article applies to:

- Microsoft FoxPro for Windows, versions 2.5x, 2.6, 2.6a
- Microsoft FoxPro for MS-DOS, versions 2.5x, 2.6, 2.6a
- Microsoft FoxPro for Macintosh, versions 2.5b, 2.5c

## SUMMARY

Once you know the formula used to create the number that is used for the TIMESTAMP field in Project files, you can use that information to decipher the time stamp of existing records, or create your own time stamp.

## MORE INFORMATION

To decipher the number, do the following:

1. Convert the number to a 32-bit binary number. For example,

          481522543

       becomes:

          0001 1100 1011 0011 0111 0011 0110 1111

       NOTE: Some calculators drop the leading zeros when they convert from
       decimal to binary, so make sure you have all 32 bits.

2. Use the following example to convert the binary number to a time stamp:

          YYYY YYYM MMMD DDDD HHHH HMMM MMMS SSSS
          0001 1100 1011 0011 0111 0011 0110 1111

          Y = year    = 0000 1110 = 14

          M = month   = 0000 0101 =  5

          D = day     = 0001 0011 = 19

          H = hour    = 0000 1110 = 14

          M = minutes = 0001 1011 = 27

          s = seconds = 0000 1111 = 15

3. The rightmost bit for seconds is missing, so change it in the following

       fashion to get the actual seconds to use in the final conversion:

          s = seconds = 0001 1110 = 30

       NOTE: This is the same result as multiplying the first value by 2, which
       means you will never have an odd number of seconds.

Years begin at 1980, so in this case you get 1994.

Everything else starts at 0, so your end result is 5/19/1994 14:27:30.

Additional reference words: FoxMac FoxDos FoxWin 2.50 2.50a 2.50b 2.50c 2.60 2.60a KBCategory: kbprg KBSubcategory: FxtoolGeneral

Last Reviewed: June 27, 1995 © 1999 Microsoft Corporation. All rights reserved. Terms of Use.