Esempio n. 1
0
        // This reads from a data row
        public static NoteItem FromDataRow(DataTableRow r)
        {
            NoteItem i = new NoteItem();

            i.id   = r.GetLong("id");
            i.note = r.GetString("note");
            return(i);
        }
Esempio n. 2
0
        // This reads from a data row
        public static GroceriesItem FromDataRow(DataTableRow r)
        {
            GroceriesItem i = new GroceriesItem();

            i.name  = r.GetString("name");
            i.count = r.GetLong("count");
            i.list  = r.GetInt("list");
            return(i);
        }
Esempio n. 3
0
        // This reads from a data row
        public static AgendaItem FromDataRow(DataTableRow r)
        {
            AgendaItem i = new AgendaItem();

            i.id              = r.GetLong("id");
            i.color           = (ColorIndex)r.GetInt("color");
            i.description     = r.GetString("description");
            i.startdate       = new DateTime(r.GetLong("startdate"));
            i.originstartdate = i.startdate;
            i.duration        = new TimeSpan(r.GetLong("duration"));
            i.alarm           = r.GetBool("alarm");
            i.alarmdate       = new DateTime(r.GetLong("alarmdate"));
            i.recur           = (AgendaItemRecur)r.GetInt("recur");
            i.recursions      = 0;
            return(i);
        }