Skip to content

[Feature]Add backing dependency property for DataGridColumn.Header #4945

Open
@Qiu233

Description

@Qiu233

Describe the problem

For now, DataGridColumn.Header is just a thin wrapper over headerCell.Content = _header.
When only values set, everything works fine. But when a binding is provided by some MarkupExtension, something like Microsoft.UI.Xaml.Binding is shown in the header rather than evaluated.
Provided binding does work in other normal cases, and according to the source code, I guess this issue is because DataGridColumn.Header has no corresponding DependencyProperty.

Describe the solution

This could be solved by

  1. adding a dependency property for DataGridColumn.Header, and then
  2. headerCell having another binding its Content to this property.

Alternatives

No response

Additional info

No response

Help us help you

None

Metadata

Metadata

Assignees

No one assigned

    Labels

    feature request 📬A request for new changes to improve functionality

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions