	interface to subroutine NtTime [c, alias: '_NtTime']
     *       (year, month, day, hours, minutes, seconds, hunds)
	integer*4 year, month, day, hours, minutes, seconds, hunds
	end

	interface to subroutine DosTime [c, alias: '_DosTime']
     *       (year, month, day, hours, minutes, seconds, milli)
	integer*4 year, month, day, hours, minutes, seconds, milli
	end

	program fortime
	integer*2 year
	integer*1 month, day, hours, minutes, seconds, hunds

        integer*2 sysyear, sysmonth, sysday, syshours, sysminutes
        integer*2 syssec, sysmili

        data sysyear, sysmonth, sysday, syshours, sysminutes,
     *       syssec, sysmili /  7*0/
        data year, month, day, hours, minutes, seconds, hunds
     *      /  7*0/

	print *, "Getting System Date and Time with INT 21H"
	call DosTime(loc(year), loc(month), loc(day), loc(hours),
     *               loc(minutes), loc(seconds), loc(hunds))
	write(6,100) hours, minutes, seconds, hunds, month, day, year
100	format(' It is now ',i2,':',i2,':',i2,'.',i2,' on ',
     *         i2,'/',i2,'/',i4)

	print *, "Getting Local Date and Time with Win32"
	call NtTime(loc(sysyear), loc(sysmonth), loc(sysday),
     *              loc(syshours), loc(sysminutes), loc(syssec),
     *              loc(sysmili))
	write(6,200) syshours, sysminutes, syssec, sysmili, 
     *               sysmonth, sysday, sysyear
200	format(' It is now ',i2,':',i2,':',i2,'.',i3,' on ',
     *         i2,'/',i2,'/',i4)
	
	stop
	end
