Telerik Forums
UI for .NET MAUI Forum
1 answer
39 views

I have the followin MainPage.xaml

 


<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
             xmlns:dataControls="http://schemas.telerik.com/2022/xaml/maui"
             xmlns:mauiApp8="clr-namespace:MauiApp8"
             x:Class="MauiApp8.MainPage"
             BindingContext="{Binding Source={RelativeSource Self}}">

    <Grid Margin="10"
          ColumnDefinitions="Auto, Auto, *">
        <dataControls:RadListView Grid.Column="0"
                                  ItemsSource="{Binding FooItems}">
            <dataControls:RadListView.ItemTemplate>
                <DataTemplate x:DataType="{x:Type mauiApp8:Foo}">
                    <dataControls:ListViewTemplateCell>
                        <dataControls:ListViewTemplateCell.View>
                            <Grid ColumnDefinitions="Auto, Auto"
                                  Padding="0, 4">
                                <Label Text="{Binding Name}"
                                       TextColor="{Binding Name}" />
                                <Label Text="{Binding Description}"
                                       Grid.Column="1" />
                            </Grid>
                        </dataControls:ListViewTemplateCell.View>
                    </dataControls:ListViewTemplateCell>
                </DataTemplate>
            </dataControls:RadListView.ItemTemplate>
        </dataControls:RadListView>

        <ListView Grid.Column="1"
                  ItemsSource="{Binding FooItems}">
            <ListView.ItemTemplate>
                <DataTemplate x:DataType="{x:Type mauiApp8:Foo}">
                    <ViewCell>
                        <Grid ColumnDefinitions="Auto, Auto"
                              Padding="0, 4">
                            <Label Text="{Binding Name}"
                                   TextColor="{Binding Name}" />
                            <Label Text="{Binding Description}"
                                   Grid.Column="1" />
                        </Grid>
                    </ViewCell>
                </DataTemplate>
            </ListView.ItemTemplate>
        </ListView>

        <Border Grid.Column="2"
                Background="Green" />
    </Grid>
</ContentPage>

Why doesn't the RadListView auto size the items correctly?

First column (red circle) is the RadListView which is cutoff.

Second column is the normal ListView which displays the text fully.

Code behind if needed is this:

 


public partial class MainPage : ContentPage
{
    public List<Foo> FooItems { get; set; }

    public MainPage()
    {
        FooItems =
        [
            new Foo("Hello", "Hello World this is a long text"),
            new Foo("Hello", "Hello World this is a very very very long text")
        ];

        InitializeComponent();
    }
}

public class Foo
{
    public string Name { get; set; }
    public string Description { get; set; }

    public Foo(string name, string description)
    {
        Name = name;
        Description = description;
    }
}

Didi
Telerik team
 answered on 10 Oct 2024
1 answer
35 views

Hi,

We are migrating xamarin to maui

I saw the one issue in here like we have a custom appointmens using in the scheduler if we have switched to landscape mode then the appointment's subject is not visible instead it shows ... 3dots 

Please help me fix it

Yana
Telerik team
 answered on 09 Oct 2024
1 answer
44 views

If I bind colors with DynamicResource syntax highlighted in the following example,  the exception "The name 'sender' does not exist in the current context" is thrown ,  do you have any insights for it?  

By the way, if I use StaticResource syntax,  it works properly.

Thanks.

            <telerik:GaugeRange Color="{DynamicResource MyColor}"
                                  From="0"
                                  To="150" />   
Yana
Telerik team
 answered on 09 Oct 2024
0 answers
62 views

We noticed that switching appointmentTemplate the first time activeViewDefinition is set to week (from day) there is a long update/load time on the view, so we sought to insert a loading overlay. (activated by setting a boolean on viewmodel to true).

We switch the template by looking into  PropertyChanged event with this method:

  private void MScheduler_PropertyChanged(object sender, System.ComponentModel.PropertyChangedEventArgs e)
  {
      if (e.PropertyName == "ActiveViewDefinition")
      {
          if (MScheduler.ActiveViewDefinition != null)
          {
              if (MScheduler.ActiveViewDefinition.Title == "Day")
              {
                  MScheduler.AppointmentTemplate = this.Resources["CustomAppointmentDataTemplate"] as DataTemplate;
              }
              else
              {
                  
                  MScheduler.AppointmentTemplate = this.Resources["CustomAppointmentDataTemplateWeek"] as DataTemplate;
              }
          }
      }
  }

However setting the boolean for the loading view just before appointmentTemplate = the weektemplate from resource.

Doesn't make it load until after the scheduler is done doing the updates needed.

So my question is, is there a better way to change the appointmenttemplate(so we avoid the 2-5 second freeze on the ui) or make a loading screen work so we can hide it?

 

inLogic
Top achievements
Rank 1
 updated question on 04 Oct 2024
1 answer
48 views

Hi!

I need help.

I would like the icon to be at the end and keep the same direction as in the image
> closed
v open

 

In this example below it is at the end but changes direction.

https://www.telerik.com/forums/icon-in-accordion-header

Regards,

Rodrigo.

Yana
Telerik team
 answered on 25 Sep 2024
1 answer
63 views
Hi Team,

I am using RadListPicker in MAUI application. Title is not showing in UWP as it is showing in Android and iOS.

Here is the code I am using.

In Xaml page

    <telerikPrimitives:RadListPicker AutomationId="ProjectName" VerticalOptions="CenterAndExpand" Grid.Column="2" Placeholder="Project" DisplayLabelStyle="{StaticResource displayLabelStyle}"
                                     HorizontalOptions="CenterAndExpand" BackgroundColor="{StaticResource DefaultTransparentColor}"
                                     ItemsSource="{Binding ResourceAssignedProjects}" DisplayMemberPath="Project" SelectedItem="{Binding ResourceSelectedProject}"
                                     BorderColor="{OnPlatform iOS={StaticResource DefaultTransparentColor}}">
    <telerikPrimitives:RadListPicker.ItemTemplate>
        <DataTemplate>
            <Label AutomationId="SelectProjectHomePage" 
                       Text="{Binding Project}" 
                       HorizontalTextAlignment="Center" 
                       VerticalTextAlignment="Center" 
                       TextColor="{StaticResource DefaultBlackColor}"/>
        </DataTemplate>
    </telerikPrimitives:RadListPicker.ItemTemplate>
    <telerikPrimitives:RadListPicker.PopupSettings>
        <telerikPrimitives:PickerPopupSettings AcceptButtonStyle="{StaticResource acceptButtonStyle}" 
                                                   CancelButtonStyle="{StaticResource cancelButtonStyle}" 
                                                   HeaderLabelStyle="{StaticResource headerLabelStyle}"
                                                   HeaderLabelText="{x:Static resources:AppResources.Project}" 
                                                   PopupViewStyle="{StaticResource popupViewStyle}" 
                                                   HeaderStyle="{StaticResource headerStyle}"/>
    </telerikPrimitives:RadListPicker.PopupSettings>
</telerikPrimitives:RadListPicker>

Using following version:


MAUI with .NET 8.0
CommunityToolkit.Maui 9.0.3
Telerik.UI.for.Maui :- 7.0.0


Kindly help me out with this.


Thanks & Regards,

Dilip.
Yana
Telerik team
 answered on 19 Sep 2024
1 answer
59 views

Do we have any plan to support MAUI Linear ProgressBar like this way to show Progress can be divided into multiple segments.

About .NET MAUI Linear ProgressBar control | Syncfusion

 

Didi
Telerik team
 answered on 19 Sep 2024
1 answer
61 views

Hello,

Do you have a sample or documentation how to customize the dropdown of RadListPicker? If Yes, can you please provide me?

Thanks.

Yana
Telerik team
 answered on 18 Sep 2024
1 answer
66 views

Hi Team,

I recently came across one issue with RadDatePicker while working on WinUI i.e. after selecting the value from DatePicker popup and clicking on Ok button, the Method (method name in the attached sample is AcceptExecuted) that is bind to PickerPopupSettings.AcceptCommand is not getting executed. 

The same commend i.e. PickerPopupSettings.AcceptCommand gets executed in Android platform.

Have attached the project as well, you will be able to reproduce it in it.

 

Thanks,

Mohammed Rameez Raza;

Didi
Telerik team
 answered on 12 Sep 2024
0 answers
50 views

Why UI/UX is importance for mobile app development?

Adrian
Top achievements
Rank 1
 asked on 12 Sep 2024
Top users last month
Anislav
Top achievements
Rank 6
Silver
Bronze
Bronze
Jianxian
Top achievements
Rank 1
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Jim
Top achievements
Rank 2
Iron
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?