Where'd my ActivityDesigner togglebutton go?
-
30-09-2019 - |
Vra
It disappeared!
I'm using the standard ActivityDesigner w/Collapsible UI example:
<sap:ActivityDesigner
x:Class="WHATTHEEFF.WhaHappenToMe"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:sap="clr- namespace:Blah blah standard stuff here"
Collapsible="True">
<sap:ActivityDesigner.Resources>
<DataTemplate
x:Key="DTC">
<TextBlock
Text="Collapsed" />
</DataTemplate>
<DataTemplate
x:Key="DTE">
<TextBlock
Text="Expanded" />
</DataTemplate>
<Style
x:Key="SC"
TargetType="ContentPresenter">
<Setter
Property="ContentTemplate"
Value="{DynamicResource DTC}" />
<Style.Triggers>
<DataTrigger
Binding="{Binding Path=ShowExpanded}"
Value="true">
<Setter
Property="ContentTemplate"
Value="{DynamicResource DTE}" />
</DataTrigger>
</Style.Triggers>
</Style>
</sap:ActivityDesigner.Resources>
<ContentPresenter
Content="{Binding}"
Style="{DynamicResource SC}" />
</sap:ActivityDesigner>
Oplossing
Derp.
Root activity is not collapsible, so if you drop an Activity on a blank workflow that Activity will not be collapsible. Child activities will be.
Guess testing your collapse template by dropping your activity in an empty workflow isn't the best idea.
Gelisensieer onder: CC-BY-SA met toeskrywing
Nie verbonde aan StackOverflow