title: Adding text to a TextBlock, one character at a time
body: <p>I'm posting this so that the code is available to whomever finds it helpful.</p>
  
  <p>Slightly reduced code based on Noctis's suggestion.</p>
  
  <pre><code>StringBuilder DescriptionText = new StringBuilder();
  
  async void RunDescription(StringBuilder description)
  {
      DescriptionText = description;
  
      await Task.Delay(1000);  // Short delay before the text starts printing so the window has time to load
  
      new Thread(AddTextToTextBlock).Start();
  }
  
  void TextBlockDispatcher(string text)
  {
      TextBlock1.Dispatcher.BeginInvoke(DispatcherPriority.Normal, new Action(() =&gt; TextBlock1.Inlines.Add(text)));
  }
  
  void AddTextToTextBlock()
  {
      foreach (char c in DescriptionText.ToString())
      {
          Thread.Sleep(30);
          TextBlockDispatcher(c.ToString());
      }
  }
  </code></pre>