コード例 #1
0
            public void ReloadFromStream(Stream stream)
            {
                if (stream.Length > 0)
                {
                    RadGridViewApplicationSettings loaded = (RadGridViewApplicationSettings)serializer.ReadObject(stream);

                    FrozenColumnCount = loaded.FrozenColumnCount;

                    ColumnSettings.Clear();
                    foreach (ColumnSetting cs in loaded.ColumnSettings)
                    {
                        ColumnSettings.Add(cs);
                    }

                    FilterSettings.Clear();
                    foreach (FilterSetting fs in loaded.FilterSettings)
                    {
                        FilterSettings.Add(fs);
                    }

                    GroupSettings.Clear();
                    foreach (GroupSetting gs in loaded.GroupSettings)
                    {
                        GroupSettings.Add(gs);
                    }

                    SortSettings.Clear();
                    foreach (SortSetting ss in loaded.SortSettings)
                    {
                        SortSettings.Add(ss);
                    }
                }
            }