/* * public class TransparentPB : PictureBox { * public void New() * { * this.SetStyle(ControlStyles.Opaque, true); * this.SetStyle(ControlStyles.OptimizedDoubleBuffer, false); * } * new public CreateParams CreateParams * { * get * { * CreateParams cp = new CreateParams(); * cp.ExStyle &= 0x00000020; * return cp; * } * } * } */ private bool AlreadyUsed(int index) { bool booRetVal = false; IEnumerable <GridItem> items = GridItems.Where(GridItems => GridItems.Index == index); booRetVal = (items.Count() > 0); return(booRetVal); }
public void OnCountryChanged() { Cities = GridItems .Where(i => i.CountryId == Selected.CountryId) .Select(i => new IdNameItem() { Id = i.CityId, Name = i.City }) .Distinct() .ToList(); }
public void OnRegionChanged() { Countries = GridItems .Where(i => i.RegionId == Selected.RegionId) .Select(i => new IdNameItem() { Id = i.CountryId, Name = i.Country }) .Distinct() .ToList(); }