I'm trying to setup a binding for a Label
in a list cell, where the source of the text is a DateTime
field on the list item.
var published = new Label();
published.SetBinding(Label.TextProperty, "PublishDate");
The problem is that the label renders the text blank, even though the PublishDate for each item is not empty, which probably means it doesn't convert to the string as it should. Nevertheless, I'd also like to customize the way the date is rendered in the label's title string (the formatting), but I couldn't find a good way to do this using the property bindings. This doesn't seem to be covered in the docs or in the API documentation.