- Home
- Forum
- Xamarin.Forms
- CardTemplate without Frame on UWP Desktop
CardTemplate without Frame on UWP Desktop
I am using SfKanban CardTemplate as below. there is just a Grid in the template and no Frame. but
- On Android- it displays each element within Frame
- On UWP desktop- No Frame around each card.
Why is it different?
<kanban:SfKanban.CardTemplate>
<DataTemplate>
<Grid ColumnSpacing="0" HorizontalOptions="FillAndExpand" Padding="3" >
<Grid.HeightRequest>
<OnPlatform x:TypeArguments="x:Double">
<OnPlatform.WinPhone>
<OnIdiom x:TypeArguments="x:Double" Phone="50" Tablet="100" Desktop="150" />
</OnPlatform.WinPhone>
<OnPlatform.Android>
<OnIdiom x:TypeArguments="x:Double" Phone="50" Tablet="100" />
</OnPlatform.Android>
<OnPlatform.iOS>
<OnIdiom x:TypeArguments="x:Double" Phone="50" Tablet="100" />
</OnPlatform.iOS>
</OnPlatform>
</Grid.HeightRequest>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="3*" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
</Grid>
</DataTemplate>
</kanban:SfKanban.CardTemplate>
SIGN IN To post a reply.
2 Replies
EM
Emil
February 16, 2018 07:21 PM UTC
If I add a frame myself like below
<kanban:SfKanban.CardTemplate>
<DataTemplate>
<Frame OutlineColor="Silver" HasShadow="True" Margin="5,2" Padding="3" BackgroundColor="Transparent" VerticalOptions="FillAndExpand">
<Grid ColumnSpacing="0" HorizontalOptions="FillAndExpand">
view doesnt have any space between cards and it displays also a scrollbar. how can I also remove that scrollbar on UWP desktop?
SG
Sridharan Gajendran
Syncfusion Team
February 20, 2018 12:59 PM UTC
Hi Emil,
Thanks for contacting Syncfusion Support.
Query 1: Frame is applied by default with Grid in DataTemplate.
Since it is rendered from native. By default,
On Android: It is rendered with frame.
On UWP: It is not rendered with frame.
Query 2: Frame is not applied with margin.
This is a framework level bug. We have reported this problem to Xamarin. As of now we have resolved it in the sample level by customizing template based on platform.
Query 3: Need to hide the column scroll bar visibility in UWP.
We have achieved your requirement in sample level using custom Kanban renderer.
Please find the demo sample from the below location.
Sample: Kanban_Demo
Regards,
Sridharan
SIGN IN To post a reply.
- 2 Replies
- 2 Participants
-
EM Emil
- Feb 16, 2018 07:13 PM UTC
- Feb 20, 2018 12:59 PM UTC