/// <summary> /// Flag value 0 for Default value /// </summary> /// <param name="FlagForDefault"></param> /// <returns></returns> /// public static List <ATTApplication> GetApplicationList(int FlagForDefault) { try { List <ATTApplication> LstAppl = new List <ATTApplication>(); foreach (DataRow row in DLLApplication.GetApplicationTable().Rows) { ATTApplication obj = new ATTApplication ( int.Parse(row["Appl_ID"].ToString()), (string)row["Appl_Short_Name"], (string)row["Appl_Full_Name"], row["Description"].ToString(), "" ); LstAppl.Add(obj); } if (FlagForDefault == 0) { LstAppl.Insert(0, new ATTApplication(0, "", "-------- Select Application --------", "", "")); } return(LstAppl); } catch (Exception ex) { throw ex; } }
public static bool AddApplication(ATTApplication Applicationobj) { try { DLLApplication.AddApplication(Applicationobj); return(true); } catch (Exception ex) { throw ex; } }
public static List <ATTApplication> GetUserApplicationList(string username) { List <ATTApplication> lst = new List <ATTApplication>(); try { foreach (DataRow row in DLLApplication.GetUserApplicationTable(username).Rows) { ATTApplication obj = new ATTApplication(); obj.ApplicationID = int.Parse(row["appl_id"].ToString()); obj.ApplicationShortName = row["appl_short_name"].ToString(); obj.ApplicationDescription = row["description"].ToString(); lst.Add(obj); } return(lst); } catch (Exception ex) { throw ex; } }