Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Hi. How can I center align text with hyperlinks in it?
I need to have the some text below, and with the XAML I got it's currently not centered. In fact, Horizontal Alignment does not seem to have any effect. Hyperlinks are working fine, however.
This is inside a grid with 2 columns, and I need the ColumnSpan to be 2.
Someone just told me that HorizontalAlignment is for the entire TextBlock control, whereas TextAlignment is for the actual text content. So:
<TextBlock TextAlignment="Center" ...