Lesson Ii (Size/Time/Dat

 BBS: Inland Empire Archive
Date: 05-13-92 (16:23)             Number: 99
From: JEAN CREPEAU                 Refer#: NONE
  To: K.L. LEE                      Recvd: NO  
Subj: Lesson Ii  (Size/Time/Dat      Conf: (2) Quik_Bas
In a message to ALL, K.L. LEE wrote:
KL=>    How to write a program which can -

KL=>  * change the file TIME & DATE?  * read the Size/Time/Date of File?

KL=>  Thanks for help me again...

KL=> Best regards, K.L. Lee


Dim Regs as RegType

Open file$ for Binary as #x     ' x is any file number

Regs.AX=&h5700                  ' Get Date and Time
Call Interrupt(&h21,Regs,Regs)
        Month=Regs.DX\32 and 15
        Day=Regs.DX and 31
        Mins=Regs.CX\32 and 63
        Secs=(Regs.CX and 31)*2

Regs.AX=&h5701                  ' Set Date and Time
Regs.CX=(Hour and 15)*2048+(Mins and 63)*32+(Secs\2 and 31)
Regs.DX=(Year-1980 and 127)*512+(Month and 15)*32+(Day and 31)
Call Interrupt(&h21,Regs,Regs)

 * Origin: INTERACESS Montreal (QC) Canada (514) 528-1415 (1:167/280)
Outer Court
Echo Basic Postings

Books at Amazon:

Back to BASIC: The History, Corruption, and Future of the Language

Hackers: Heroes of the Computer Revolution (including Tiny BASIC)

Go to: The Story of the Math Majors, Bridge Players, Engineers, Chess Wizards, Scientists and Iconoclasts who were the Hero Programmers of the Software Revolution

The Advent of the Algorithm: The Idea that Rules the World

Moths in the Machine: The Power and Perils of Programming

Mastering Visual Basic .NET