home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.lang.pascal.borland      Borland Pascal was actually pretty neat      2,978 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 1,909 of 2,978   
   Robert AH Prins to All   
   Re: Help convert C function to Pascal fu   
   25 Sep 05 15:25:19   
   
   From: prino@onetel.com   
      
   "HubbleBubble"  wrote in message   
   news:1127644225.062605.87950@g47g2000cwa.googlegroups.com...   
   >   
   > Ian wrote:   
   >> As I am not familiar with the C programming language, I would   
   >> greatly appreciate it if someone could please convert the C   
   >> function below to a Pascal function. Thanks!   
   >   
   > Let's be nice and unsnotty to newbies shall we?   
   >   
   > I think this might help.   
   >   
   > program Whatever;   
   >   
   > uses DOS   
   >   
   > (* Structure used by DOS - Date & time record used by PackTime and   
   > UnpackTime   
   >   You don't need to define this since the structure is already built   
   > into  TP   
   > (**)   
   >   
   > type   
   >   DateTime = record   
   >     Year,Month,Day,Hour,   
   >     Min,Sec: Word;   
   >   end;   
   >   
   > {Look at the DOS unit for other Time/Date functions}   
   > var   
   >    Hour, Min, Sec, S100 : word;   
   >    Mama : Real;   
   >   
   > begin   
   >     GetTime(Hour,Min,Sec,S100);   
   >     Mama := (Hour * 3600) + (Min * 60) + Sec + (S100 / 100);   
   >     Writeln(Mama);   
   >     Readln;   
   > end.   
   >   
   > Untested so don't hold me to it . Enjoy :)   
      
   Obviously untested, completely missed the date!   
      
   Robert   
   --   
   Robert AH Prins   
   prino at prino dot plus dot com   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca