I'm experiencing very strange behavior. I have two managed configurations. In the first, everything works fine. In the second, I'm running into the two following problems:
1. The binding in my dockpane is not working. The dockpane is referenced in the Config.daml as follows:
<dockPane id="BiotopApp_View_Dockpanes_DockStart" caption="Objekt starten" className="BiotopApp.View.Dockpanes.DockStartViewModel" dock="group" dockWith="esri_core_projectDockPane">
<content className="BiotopApp.View.Dockpanes.DockStartView" />
</dockPane>
I define a button in DockStart.xaml as follows:
<Button x:Name="btnStart" Content="Objekt starten" Command="{Binding CommandStartObject}" IsEnabled="{Binding CommandStartEnabled}" Background ="LightGreen" HorizontalAlignment="Left" Margin="202,493.4,0,0" Grid.Row="1" VerticalAlignment="Top" Width="108" RenderTransformOrigin="0.776,-0.2" Height="26"/>
The code in DockStartViewModel for the button is as follows:
internal ICommand CommandStartObject
{
get
{
return new RelayCommand(async (args) => await StartObjectAsync(), () => true);
}
}
2. When I start the managed configuration, the following method is never called:
internal class BiosModule : Module
{
protected override bool Initialize()
{
return base.Initialize();
}
...
What am I overlooking? I am doing exactly the same things in both Managed Configurations.
One last question: how does the .xaml know to which class it is bound? It is not the following line of code:
d:DataContext="{Binding Path=DockStartViewModel}">