public void Load() { ObservableCollection <PropertyModel> properties = new ObservableCollection <PropertyModel>(); _iswixProperties = new IsWiXProperties(); foreach (var iswixProperty in _iswixProperties) { PropertyModel propertyModel = new PropertyModel(); propertyModel.Id = iswixProperty.Id; propertyModel.Value = iswixProperty.Value; propertyModel.Admin = iswixProperty.Admin; propertyModel.Hidden = iswixProperty.Hidden; propertyModel.Secure = iswixProperty.Secure; propertyModel.SuppressModularization = iswixProperty.SuppressModularization; propertyModel.PropertyChanged += PropertyModel_PropertyChanged; properties.Add(propertyModel); } Properties = properties; EnableRemove = false; }
private void LoadProperties() { dataSetProperties.Tables[0].Rows.Clear(); try { _properties = new IsWiXProperties(_mgr.DocumentManager.Document); foreach (var property in _properties) { dataSetProperties.Tables[0].Rows.Add(new object[] { property.Id, property.Value, property.SuppressModularization, property.Secure, property.Hidden, property.Admin }); } } catch (Exception ex) { MessageBox.Show(ex.Message); } }