In VB2010 WPF, i have a textblock which, when the window loads, i need the text inside the textblock to be the same as the text in an outside .txt file. How can i do this?
Thanks
Nick
In VB2010 WPF, i have a textblock which, when the window loads, i need the text inside the textblock to be the same as the text in an outside .txt file. How can i do this?
Thanks
Nick
<Window
...
Loaded="Window_Loaded">
...
<TextBlock Name="textBlock" .../>
...
</Window>
and...
private void Window_Loaded(object sender, RoutedEventArgs e)
{
textBlock.Text = System.IO.File.ReadAllText(path);
}