Not sure how to go about this. I am trying to set-up a DataGridHyperlinkColumn
in the code-behind so that all the links point to the same URI but each has a different attribute value.
Here is what I have so far:
DataGridHyperlinkColumn dgCol = new DataGridHyperlinkColumn();
dgCol.Header = title;
dgCol.ContentBinding = new Binding("PersonName");
dgCol.Binding = "PersonEditPage.xaml?PersonID=" + Binding("PersonID");
Of course dgCol.Binding
is expecting a Binding object and so I can't just add a string to this. Can you please help me to create this binding correctly?
I have not been able to find anything helpful, but maybe this is because I don't know what I should be looking for. Here are some things I have been looking at (If I missed something please forgive me):