public SessionNote SessionNoteModification(string action, int id, string note)
 {
     SqlParameter[] sqlParms = new SqlParameter[]{
         new SqlParameter("@action",action),
         new SqlParameter("@id",id),
         new SqlParameter("@note",note)
     };
     var sessionNote = new IGNITE_MODEL.SessionNote.SessionNote();
     using (SqlDataReader sqlobj = SqlHelper.ExecuteReader(SqlHelper.ConnectionString, CommandType.StoredProcedure, "sp_hick_SessionNote_Modification", sqlParms))
     {
         while (sqlobj.Read())
         {
             sessionNote.Id = DBHelper.getInt(sqlobj, "Id");
             sessionNote.Date = DBHelper.getDateTime(sqlobj, "Date").ToString("MMMM dd, yyyy");
             sessionNote.Category = GetActionTypeString(DBHelper.getInt16(sqlobj, "Category"));
             sessionNote.Note = DBHelper.getString(sqlobj, "Note");
             sessionNote.StartTime = DBHelper.getDateTime(sqlobj, "StartTime").ToShortTimeString();
             sessionNote.EndTime = DBHelper.getDateTime(sqlobj, "EndTime").ToShortTimeString();
             TimeSpan totaltime = (DBHelper.getDateTime(sqlobj, "EndTime").Subtract(DBHelper.getDateTime(sqlobj, "StartTime")));
             sessionNote.TotalTime = ToLongString(totaltime);
         }
     }
     return sessionNote;
 }
 public List<SessionNote> GetSessionNote(string userid,int peerId,int PageIndex,int PageSize)
 {
     SqlParameter[] sqlParms = new SqlParameter[]{
         new SqlParameter("@UserId",userid),
         new SqlParameter("@PeerId",peerId)
     };
     var sessionNoteList = new List<SessionNote>();
     using (SqlDataReader sqlobj = SqlHelper.ExecuteReader(SqlHelper.ConnectionString, CommandType.StoredProcedure, "sp_hick_GetSessionNote", sqlParms))
     {
         while (sqlobj.Read())
         {
             var sessionNote = new IGNITE_MODEL.SessionNote.SessionNote();
             sessionNote.Id = DBHelper.getInt(sqlobj, "Id");
             sessionNote.Date = DBHelper.getDateTime(sqlobj, "Date").ToString("MMM dd,yyyy");
             sessionNote.Category = GetActionTypeString(DBHelper.getInt(sqlobj, "Category"));
             sessionNote.Note = DBHelper.getString(sqlobj, "Note");
             sessionNote.StartTime = string.Format("{0:hh:mm tt}", DBHelper.getDateTime(sqlobj, "StartTime"));
             sessionNote.EndTime = string.Format("{0:hh:mm tt}", DBHelper.getDateTime(sqlobj, "EndTime"));
             TimeSpan totaltime = (DBHelper.getDateTime(sqlobj, "EndTime").Subtract(DBHelper.getDateTime(sqlobj, "StartTime")));
             sessionNote.TotalTime = ToLongString(totaltime);
             sessionNoteList.Add(sessionNote);
         }
     }
     return sessionNoteList;
 }