Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to bind DataGridTemplateColumn.SortMemberPath to an instance of an array #16424

Open
cornerbowlsoftware opened this issue Jul 23, 2024 · 0 comments
Labels

Comments

@cornerbowlsoftware
Copy link

Describe the bug

In WPF I am able to assign an instance within an array to the DataGridTemplateColumn.SortMemberPath, however, in Avalonia this does not work. The sample code causes the sort arrow to no longer display and sorting to be ignored:

            var clm = new DataGridTemplateColumn()
            {
                Header = name,
                SortMemberPath = $"{nameof(MyCoreClass.Values)}[{i}]",
                CellTemplate = template,
            };

I have attached a sample program that exposes the bug.

SortMemberPathBug.zip

To Reproduce

Run the sample program. Click on each of the 4 column headers. Notice the first three do not sort, however the last hard coded column sorts.

Expected behavior

The SortMemberPath should correctly sort the rows.

Avalonia version

11.1.0

OS

No response

Additional context

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant