Skip to content

Commit 4140b12

Browse files
authored
Update README.md
1 parent ae18c0e commit 4140b12

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# add-item-to-group-in-specific-index-.net-maui-listview
22
How to add an item at a specific index in grouped .NET MAUI ListView (SfListView) ?
33

4-
In [.NET MAUI ListView (SfListView)](https://www.syncfusion.com/maui-controls/maui-listview), you can add an item at a specific index in a specific group by using the `KeySelector` property and the Key value of each group. Since, each group is identified by its `Key,`which holds the underlying data related to the group. When a new item is added at runtime, you need to find which group the item belongs to by using `PropertyInfoCollection,` `PropertyName,` and `KeySelector `and after getting the desired group’s `GroupResult` value, insert the particular item into a specified index.
4+
In [.NET MAUI ListView (SfListView)](https://www.syncfusion.com/maui-controls/maui-listview), you can add an item at a specific index in a specific group by using the `KeySelector` property and the Key value of each group. Since, each group is identified by its `Key,`which holds the underlying data related to the group. When a new item is added at runtime, you need to find which group the item belongs to by using `PropertyInfoCollection`, `PropertyName` and `KeySelector`and after getting the desired group’s `GroupResult` value, insert the particular item into a specified index.
55
C#
66
To add new data to the underlying collection in the ViewModel class,
77
```c#
@@ -13,7 +13,7 @@ contact.ContactImage ="image"+r.Next(0, 28)+".png";
1313
ViewModel.ContactItems.Add(contact);
1414
```
1515

16-
You can determine which group does the newly added item belongs to by using the `KeySelector `property and `Key` value of the group by passing the underlying data into the parameter in the `GetGroupResult` method.
16+
You can determine which group does the newly added item belongs to by using the `KeySelector`property and `Key` value of the group by passing the underlying data into the parameter in the `GetGroupResult` method.
1717
```c#
1818
internal void GetGroupResult(object ItemData)
1919
{

0 commit comments

Comments
 (0)