protected void Page_Load(object sender, EventArgs e)
        {
            if (!Page.IsPostBack)
            {
                AssetContext db = new SAAssetManagement.Models.AssetContext();
                var divisions = db.Divisions;

                foreach (var div in divisions)
                {
                    DropDownList1.Items.Add(new ListItem(div.DivisionName, div.DivisionID.ToString()));
                }
                DropDownList1.Items.Insert(0, new ListItem("---All Divisions---", ""));
                DropDownList1.SelectedIndex = 0;

                var users = from c in db.Employees select new {employeeid = c.EmployeeID,FullNames = c.EmployeeFirstName + " " + c.EmployeeLastName };

                foreach (var user in users)
                {
                    DropDownList2.Items.Add(new ListItem(user.FullNames, user.employeeid.ToString()));
                }
                DropDownList2.Items.Insert(0, new ListItem("---All Users---", ""));
                DropDownList2.SelectedIndex = 0;

                Label1.Visible = false;
            }
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!Page.IsPostBack)
            {
                AssetContext db        = new SAAssetManagement.Models.AssetContext();
                var          divisions = db.Divisions;

                foreach (var div in divisions)
                {
                    DropDownList1.Items.Add(new ListItem(div.DivisionName, div.DivisionID.ToString()));
                }
                DropDownList1.Items.Insert(0, new ListItem("---All Divisions---", ""));
                DropDownList1.SelectedIndex = 0;

                var users = from c in db.Employees select new { employeeid = c.EmployeeID, FullNames = c.EmployeeFirstName + " " + c.EmployeeLastName };

                foreach (var user in users)
                {
                    DropDownList2.Items.Add(new ListItem(user.FullNames, user.employeeid.ToString()));
                }
                DropDownList2.Items.Insert(0, new ListItem("---All Users---", ""));
                DropDownList2.SelectedIndex = 0;

                Label1.Visible = false;
            }
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!Page.IsPostBack)
            {
                AssetContext db        = new SAAssetManagement.Models.AssetContext();
                var          divisions = db.Divisions;

                foreach (var div in divisions)
                {
                    DropDownList1.Items.Add(new ListItem(div.DivisionName, div.DivisionID.ToString()));
                }
                DropDownList1.Items.Insert(0, new ListItem("---All Divisions---", ""));
                DropDownList1.SelectedIndex = 0;

                var assetTypes = db.AssetTypes;

                foreach (var assetType in assetTypes)
                {
                    DropDownList2.Items.Add(new ListItem(assetType.AssetTypeName, assetType.AssetTypeID.ToString()));
                }
                DropDownList2.Items.Insert(0, new ListItem("---All Asset Types---", ""));
                DropDownList2.SelectedIndex = 0;

                Label1.Visible = false;
            }
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!Page.IsPostBack)
            {
                AssetContext db = new SAAssetManagement.Models.AssetContext();
                var divisions = db.Divisions;

                foreach (var div in divisions) {
                    DropDownList1.Items.Add(new ListItem(div.DivisionName,div.DivisionID.ToString()));
                }
                DropDownList1.Items.Insert(0, new ListItem("---All Divisions---", ""));
                DropDownList1.SelectedIndex = 0;

                var assetTypes = db.AssetTypes;

                foreach (var assetType in assetTypes)
                {
                    DropDownList2.Items.Add(new ListItem(assetType.AssetTypeName, assetType.AssetTypeID.ToString()));
                }
                DropDownList2.Items.Insert(0, new ListItem("---All Asset Types---", ""));
                DropDownList2.SelectedIndex = 0;

                Label1.Visible = false;
            }
        }