Example #1
0
        public DataTable GetDateTable()
        {
            DataTable        table   = new DataTable("Dates");
            SqlCeDataAdapter adapter = PTDatabase.GetAdaperForDatesView();

            adapter.Fill(table);
            return(table);
        }
Example #2
0
        public DataTable GetProcessInfoTableForDate(DateTime datetime)
        {
            DataTable        table   = new DataTable("ProcessInfos");
            PTDate           date    = PTDatabase.GetDateForDateTime(datetime);
            SqlCeDataAdapter adapter = PTDatabase.GetAdaperForProcessInfosViewForDate(date);

            adapter.Fill(table);
            return(table);
        }
Example #3
0
        public static void HandleRecord(PTRecord record)
        {
            PTDate date = PTDatabase.GetDateForDateTime(record.datetime);

            if (!PTDatabase.UpdateProcessTime(record.name, date, record.time))
            {
                PTDatabase.InsertProcessInfo(record.name, record.time, date);
            }
        }