- Home
- Forum
- Xamarin.Forms
- navigation drawer in control template wont show a navigation drawer as its content presenter
navigation drawer in control template wont show a navigation drawer as its content presenter
Hi
I'm using navigation Drawer in a control template like below
<ControlTemplate x:Key="masterTemplate">
<navigationdrawer:SfNavigationDrawer
FlowDirection="LeftToRight"
x:Name="navigationDrawer"
DrawerFooterHeight="0"
DrawerHeaderHeight="0"
DrawerWidth="260"
Position="Right"
VerticalOptions="FillAndExpand">
<navigationdrawer:SfNavigationDrawer.ContentView>
<StackLayout Spacing="0">
<Grid HeightRequest="60" BackgroundColor="{StaticResource primaryBlue}">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="40" />
</Grid.ColumnDefinitions>
<control:IconButton
Grid.Column="1"
BackgroundColor="Transparent"
BindingContext="{x:Reference navigationDrawer}"
Clicked="ToggleMenu"
TextColor="{StaticResource buttonTextWhite}"
FontSize="{StaticResource largeFontSize}"
HorizontalOptions="End"
Text=""
Type="Solid" />
<Label
HorizontalTextAlignment="Start"
VerticalTextAlignment="Center"
FontFamily="{StaticResource Shabnam-Bold-FDFont}"
FontSize="{StaticResource mediumFontSize}"
TextColor="{StaticResource buttonTextWhite}"
Text="{TemplateBinding Title}" />
</Grid>
<ContentPresenter x:Name="ContentPresenter" VerticalOptions="FillAndExpand" />
</StackLayout>
</navigationdrawer:SfNavigationDrawer.ContentView>
<navigationdrawer:SfNavigationDrawer.DrawerContentView>
<control:MenuView NavigationDrawer="{x:Reference navigationDrawer}" bitViewProps:PartialViewProps.PartialViewParentPage="{TemplateBinding}"/>
</navigationdrawer:SfNavigationDrawer.DrawerContentView>
</navigationdrawer:SfNavigationDrawer>
</ControlTemplate>
then when i try to control template of my page which has navigation drawer in it , it wont show content presenter and just show a white view. is there any way that i can do this?
SIGN IN To post a reply.
5 Replies
EM
Emil
February 7, 2019 11:38 PM UTC
are you using v16.4.0.52 ? i have same problem with the latest release. try version before. it works for me
MK
mohammad kamali
February 8, 2019 07:23 AM UTC
Hi
i did try the version that you said but it still id not working
SK
Selva Kumar Veerakrishnan
Syncfusion Team
February 11, 2019 04:02 AM UTC
Hi Mohammad,
Greetings from Syncfusion.
In the given code snippet, we have noticed that the SfNavigationDrawer control is used in the ControlTemplate but we could not find the target type to which this Template is assigned. Could you please provide more details like to which control this ControlTemplate has been used? This will be helpful for us to provide better solution on this.
Regards,
Selva Kumar V.
Greetings from Syncfusion.
In the given code snippet, we have noticed that the SfNavigationDrawer control is used in the ControlTemplate but we could not find the target type to which this Template is assigned. Could you please provide more details like to which control this ControlTemplate has been used? This will be helpful for us to provide better solution on this.
Regards,
Selva Kumar V.
PA
Pawel
February 13, 2019 03:06 PM UTC
Hi,
I encountered the same problem with version v16.4.0.52. After updating up to 0.53 everything works like a charm.
Regards.
Paul.
DR
Dhanasekar R
Syncfusion Team
February 14, 2019 05:48 AM UTC
Hi Paul,
Glad that the issue has been resolved. Please get back to us if any further assistance on this.
Regards,
Dhanasekar
SIGN IN To post a reply.
- 5 Replies
- 5 Participants
-
MK mohammad kamali
- Feb 6, 2019 03:04 PM UTC
- Feb 14, 2019 05:48 AM UTC