Popup with RadGrid

1 Answer 117 Views
DataGrid Popup
Daniel
Top achievements
Rank 1
Silver
Bronze
Daniel asked on 21 Mar 2022, 03:12 PM

Hi,

I would like to get small sample when I click on grid a popup will be show with data in MVVM manner.

Thanks,

 

Daniel
Top achievements
Rank 1
Silver
Bronze
commented on 21 Mar 2022, 05:39 PM

Hi,

1. I have already funcuality when user select row in grid and press delete button i removed the row.

It done by bindind the selected item to view model and with command button i delete the row.

2. I want to use second approach-which event i can fire in mvvm manner on grid to fire modal page?


Lance | Manager Technical Support
Telerik team
commented on 21 Mar 2022, 05:53 PM | edited

Please visit the Commands article to understand what commands are available for you at this time .NET MAUI DataGrid Documentation | Overview | Telerik UI for .NET MAUI.  The commands and parameters are what is available to you. What you do inside those commands is up to to you (i.e., we cannot assist with your custom business logic).

Keep in mind that even the SDK Browser examples are very minimal at this time, UI for MAUI is a preview product and is under heavy development. when we are done with feature development, we can spend time adding more demo. In the meantime, you can always use the UI for Xamarin.Forms demos as a big head start because the implementation is nearly identical  xamarin-forms-sdk/XamarinSDK/SDKBrowser/SDKBrowser/Examples/DataGridControl at master · telerik/xamarin-forms-sdk (github.com)

1 Answer, 1 is accepted

Sort by
0
Lance | Manager Technical Support
Telerik team
answered on 21 Mar 2022, 04:53 PM | edited on 21 Mar 2022, 05:49 PM

Hello Daniel,

We do not have such an example available for this. I will suggest it to the development team to consider in the official examples in the future. Note that it is not a guarantee that we will build such a demo as there are many factors that go into an official example.

So, I recommend that you move forward with your custom app development for your custom business app design requirements. If you have trouble with designing or building such a custom business requirement, you could also ask the open source community for help with building it using GitHub (or similar).

Before you do that, I have some information that you should be aware of before starting.

Beware - 'Gotchas'

It is not recommended to use components that use UI Virtualization inside a popup (TreeView, RadListView, DataGrid, etc). In the best of situations, you'll have a sluggish app because all the data items were actualized (even though you can't see them). In the worst, you do not see anything or you get an OutOfMemoryException.

Important: If you must move forward with such a design concept, then you must explicitly define dimensions for the DataGrid (WidthRequest/HeightRequest) when it is inside a popup that doesn't have strict outer measurements. This is in order for the measure & arrange passes to properly work. Please visit this article for an explanation and options to move forward => Controls Are Not Appearing | Telerik UI for Xamarin.

 

<RadDataGrid WidthRequest="200" HeightRequest="100" />

 

Note: You cannot use MinWidth or any other dynamic type of dimensions to try and work around this. This is just a fundamental nature of how UI virtualization works and what you need to provide that virtualized component to understand its outer bounds.

Alternative

I would instead recommend that you use a modal page to show a transient UI with such a design goal. If you would like assistance with page navigation. For example Navigation.PushModal(MyDataGridPopupPage).

For any further guidance for general/custom business app design requirements and navigation, you can ask the Xamarin.Forms and MAUI community here dotnet-xamarinforms - Microsoft Q&A.

Regards,
Lance | Manager Technical Support
Progress Telerik

[Edit 1] spelling corrections and added link to documentation article and external help options.

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Tags
DataGrid Popup
Asked by
Daniel
Top achievements
Rank 1
Silver
Bronze
Answers by
Lance | Manager Technical Support
Telerik team
Share this question
or