public override object EditValue(ITypeDescriptorContext context, IServiceProvider provider, object value) { try { var relation = (Relation)context.Instance; var edSvc = (System.Windows.Forms.Design.IWindowsFormsEditorService)provider.GetService(typeof(System.Windows.Forms.Design.IWindowsFormsEditorService)); var F = new nHydrate.Generator.Forms.ColumnRelationshipCollectionEditorForm(relation); if(edSvc.ShowDialog(F) == System.Windows.Forms.DialogResult.OK) { context.OnComponentChanged(); } } catch(Exception ex) { } return value; }
public override object EditValue(ITypeDescriptorContext context, IServiceProvider provider, object value) { try { var relation = (Relation)context.Instance; var edSvc = (System.Windows.Forms.Design.IWindowsFormsEditorService)provider.GetService(typeof(System.Windows.Forms.Design.IWindowsFormsEditorService)); var F = new nHydrate.Generator.Forms.ColumnRelationshipCollectionEditorForm(relation); if (edSvc.ShowDialog(F) == System.Windows.Forms.DialogResult.OK) { context.OnComponentChanged(); } } catch (Exception ex) { } return(value); }
private bool EditItem() { if (lvwMembers.SelectedItems.Count == 0) { return(false); } var relation = lvwMembers.SelectedItems.FirstOrDefault <ListViewItem>().Tag as Relation; var F = new nHydrate.Generator.Forms.ColumnRelationshipCollectionEditorForm(relation); if (F.ShowDialog() == System.Windows.Forms.DialogResult.OK) { this.LoadList(); return(true); } return(false); }
private bool EditItem() { if (lvwMembers.SelectedItems.Count == 0) return false; var relation = lvwMembers.SelectedItems.FirstOrDefault<ListViewItem>().Tag as Relation; var F = new nHydrate.Generator.Forms.ColumnRelationshipCollectionEditorForm(relation); if (F.ShowDialog() == System.Windows.Forms.DialogResult.OK) { this.LoadList(); return true; } return false; }