in ASP displaying date from TPS files stored as Long 
Author Message
 in ASP displaying date from TPS files stored as Long

Hi Everbody
Does anyone know how to display dat ein Clarion/ASP from TPS files where it

standard format option in ASP template, it does display the date but wrong
date.

Any experience with this???

Any help much appreciated.

Thank You

Regards
Vikas Gupta



Sun, 22 May 2005 08:54:02 GMT  
 in ASP displaying date from TPS files stored as Long
This is because the Clarion standard date is the number of days since 28th
December, 1800. Other programs use Julian dates i.e since 1st January 4713BC
(I think)

Therefore if you use a LONG you need to add a number of days to the clarion
date. I think it is as below:

ASPDate = MyDate + 2378857

Or change your LONG's to DATE types in your dict.

HTH

--
Regards,

Trevor{*filter*}s
Data Design Services Ltd


Web: www.ddssoftware.co.uk

Tel: +44 (0)23 8024 0470
Fax: +44 (0)23 8025 2573

Supplier of Printers MIS software written in Clarion.


Quote:
> Hi Everbody
> Does anyone know how to display dat ein Clarion/ASP from TPS files where
it

> standard format option in ASP template, it does display the date but wrong
> date.

> Any experience with this???

> Any help much appreciated.

> Thank You

> Regards
> Vikas Gupta



Sun, 22 May 2005 20:48:14 GMT  
 in ASP displaying date from TPS files stored as Long
This is code I use in my ASP files (not using ASP templates):

ASPDate = DateAdd("d", ClarionDate, DateSerial(1800, 12, 28))

HTH,
Walter Hissink



Quote:
> Hi Everbody
> Does anyone know how to display dat ein Clarion/ASP from TPS files where
it

> standard format option in ASP template, it does display the date but wrong
> date.

> Any experience with this???

> Any help much appreciated.

> Thank You

> Regards
> Vikas Gupta



Sun, 22 May 2005 23:03:11 GMT  
 in ASP displaying date from TPS files stored as Long

Quote:
> Does anyone know how to display dat ein Clarion/ASP from TPS files where it

> standard format option in ASP template, it does display the date but wrong
> date.

FWIW - if you are using VBScript to display dates then VBScript uses 12/30/1899
as its base date while CW uses 12/28/1800. I'll leave you to code the
function<g>.

Brian Staff (Phoenix)



Mon, 23 May 2005 01:02:09 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. DATE vs LONG in .tps files and ODBC

2. Beta TPS ODBC (long) Date conversion ?

3. Using Long File Names (TPS Files) in Clarion

4. Connecting Clarion/ASP to TPS Files

5. TPS Files No longer supported in CFD w/Win95

6. LONG in TPS file doesn't show negative numbers

7. how to store a date in a file with mxDateTime

8. .asp or .inc for include files in ASP

9. Clarion Date (Long) -> Access Date\Time

10. TPS and ASP

11. Clarion ASP Templates and TPS

12. TPS ODBC and MS IIS/ASP

 

 
Powered by phpBB® Forum Software