Add an adapter with arguments to a connection in any composition. A scenario is illustrated in the attached TableFormArguments1.PNG where I have used the supplied "Copy To File" as the adapter. You can see the adapter has 4 arguments. Clicking on the Arguments button with the legend "4" should put up a view in which the four arguments and be viewed and edited.
When the Arguments button is clicked the crash shown in the attached TableFormArguments2.PNG occurs. Clearly Item needs to be initialised.
I have made the following changes locally to work around the problem:
Diff for TableFormArguments.cs:
@@ -26,6 +26,11 @@ namespace FluidEarth2.Pipistrelle.UiBase
}
}
+ public TableFormArguments(IDescribable item)
+ {
+ Item = item;
+ }
+
public override void Initialise(Form parent, IHostingApp host, MenuControlExtension.ModeOptions mode)
{
base.Initialise(parent, host, mode);
Diff for TableFormExchangeItem.cs:
@@ -182,7 +182,7 @@ namespace FluidEarth2.Pipistrelle.UiBase
? MenuControlExtension.ModeOptions.Browse
: MenuControlExtension.ModeOptions.Edit;
- var dlg = new TableFormArguments();
+ var dlg = new TableFormArguments(adapted);
dlg.Initialise(Owner, Host, mode);
if (dlg.ShowDialog(adapted) == DialogResult.OK)
Anonymous