Label Provider/DataForm behaviour

9 posts, 0 answers
  1. Mikas
    Mikas avatar
    7 posts
    Member since:
    Aug 2016

    Posted 18 Oct 2017 Link to this post

    I am wondering if anyone has seen behavior like this.

    I am using MVVM and Prism as well.

    Everything appears totally fine and the Provider gives the list of items to select from and works perfectly ... on the first selection.

    The remaining selections do not update the form (Set is never called).

    If you force a page refresh (change device orientation) everything updates correctly, set is called and you are good again ... for ONE selection.

    Then you are back in the same boat.

     

    Any help appreciated.

     

     

     

     

     

  2. Mikas
    Mikas avatar
    7 posts
    Member since:
    Aug 2016

    Posted 18 Oct 2017 in reply to Mikas Link to this post

    I created a sample program and while doing that discovered a wrinkle.

    I created a ticket in your system and attached the sample program.

    Mike

  3. Nikolay
    Admin
    Nikolay avatar
    37 posts

    Posted 23 Oct 2017 Link to this post

    Hello, Mike,

    I can confirm that this is an issue in our DataForm implementation for Android. It seems like the problem is reproducible when the DataForm is nested inside multiple layouts. I have logged a Bug Report in our backlog about this behavior. Here is a link to the public item in our Feedback Portal where you can track the progress on the matter.
     
    As a workaround I would suggest setting the VerticalOptions of the outer layout - any value for the VerticalOptions should fix the problem.

    I hope I've been helpful.

    Regards,
    Nikolay
    Progress Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  4. Craig
    Craig avatar
    6 posts
    Member since:
    May 2016

    Posted 23 Oct 2017 in reply to Nikolay Link to this post

    Hi Nickolay

    Your workaround does not appear to work for me.  I have the following xaml and have I've tried VerticalOptions at all levels as well as individual levels.

    Cheers
    Craig

    <?xml version="1.0" encoding="utf-8" ?>
                 xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
                 xmlns:input="clr-namespace:Telerik.XamarinForms.Input;assembly=Telerik.XamarinForms.Input"
                 xmlns:dataForm="clr-namespace:Telerik.XamarinForms.Input.DataForm;assembly=Telerik.XamarinForms.Input"
                 x:Class="ccnz.mobile.Pages.LoanApplication.ExpensesPage">
        <ContentPage.Content>
            <ScrollView VerticalOptions="FillAndExpand">
                <StackLayout VerticalOptions="FillAndExpand">
                    <Label Text="Financial Expenses"/>
                    <input:RadDataForm x:Name="ExpensesDataForm" Source="{ Binding Expenses }" VerticalOptions="FillAndExpand">
                        <input:RadDataForm.GroupLayoutDefinition>
                            <dataForm:DataFormGroupGridLayoutDefinition />
                        </input:RadDataForm.GroupLayoutDefinition>
                    </input:RadDataForm>
                    <StackLayout Orientation="Horizontal" Margin="10, 0, 10, 0">
                        <Button Text="Previous" Clicked="PreviousButtonClicked" HorizontalOptions="FillAndExpand" />
                        <Button Text="Next" Clicked="NextButtonClicked" HorizontalOptions="FillAndExpand" />
                    </StackLayout>
                </StackLayout>
            </ScrollView>
        </ContentPage.Content>
    </ContentPage>
     
  5. Mikas
    Mikas avatar
    7 posts
    Member since:
    Aug 2016

    Posted 23 Oct 2017 in reply to Craig Link to this post

    I have a similarly designed form and am finding the same thing.

    Mike

  6. Nikolay
    Admin
    Nikolay avatar
    37 posts

    Posted 26 Oct 2017 Link to this post

    Hello Mike, Craig,

    The bug is already logged at our end. After some further tests it seems that the issue is not present in the following setup:

    <ContentPage.Content>
        <ScrollView VerticalOptions="FillAndExpand" HorizontalOptions="CenterAndExpand">
            <StackLayout VerticalOptions="FillAndExpand">
                <Label Text="Financial Expenses"/>
                <input:RadDataForm x:Name="ExpensesDataForm" Source="{ Binding Expenses }" VerticalOptions="FillAndExpand">
                    <input:RadDataForm.GroupLayoutDefinition>
                        <dataForm:DataFormGroupGridLayoutDefinition />
                    </input:RadDataForm.GroupLayoutDefinition>
                </input:RadDataForm>
                <StackLayout Orientation="Horizontal" Margin="10, 0, 10, 0">
                    <Button Text="Previous" Clicked="PreviousButtonClicked" HorizontalOptions="FillAndExpand" />
                    <Button Text="Next" Clicked="NextButtonClicked" HorizontalOptions="FillAndExpand" />
                </StackLayout>
            </StackLayout>
        </ScrollView>
    </ContentPage.Content>

    You can notice that I've added HorizontalOptions="CenterAndExpand" to the outer layout - in your case that is the ScrollView. You can give it a try at your end, however, we have not fully tested it, so it might have some flaws as well.

    Regards,
    Nikolay
    Progress Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  7. Mikas
    Mikas avatar
    7 posts
    Member since:
    Aug 2016

    Posted 26 Oct 2017 in reply to Nikolay Link to this post

    I modified mine to be closer to this new example and I appear to be in much better shape than before.

    Thanks Nikolay.

  8. Craig
    Craig avatar
    6 posts
    Member since:
    May 2016

    Posted 26 Oct 2017 Link to this post

    Thanks Nickolay.  My data form appears to be behaving itself now too.

    Cheers
    Craig

  9. Nikolay
    Admin
    Nikolay avatar
    37 posts

    Posted 30 Oct 2017 Link to this post

    Hello Mike, Craig,

    I am glad to see that the provided solution works for you. If you need some additional information do not hesitate to write back.

    Regards,
    Nikolay
    Progress Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top