title: Extract texts from xps document to textbox
body: <p>I keep running in to this code when researching, however copying this to my form gives me an error in the <code>documentViewerElement</code> part saying <code>The name 'documentViewerElement' does not exist in the current context</code></p>
  
  <pre><code>XpsDocument _xpsDocument=new XpsDocument("/path",System.IO.FileAccess.Read);
  IXpsFixedDocumentSequenceReader fixedDocSeqReader 
      =_xpsDocument.FixedDocumentSequenceReader;
  IXpsFixedDocumentReader _document = fixedDocSeqReader.FixedDocuments[0];
  IXpsFixedPageReader _page 
      = _document.FixedPages[documentViewerElement.MasterPageNumber];
  StringBuilder _currentText = new StringBuilder();
  System.Xml.XmlReader _pageContentReader = _page.XmlReader;
  if (_pageContentReader != null)
  {
    while (_pageContentReader.Read())
    {
      if (_pageContentReader.Name == "Glyphs")
      {
        if (_pageContentReader.HasAttributes)
        {
          if (_pageContentReader.GetAttribute("UnicodeString") != null )
          {                                   
            _currentText.
              Append(_pageContentReader.
              GetAttribute("UnicodeString"));                              
          }
        }
      }
    }
  }
  string _fullPageText = _currentText.ToString();
  </code></pre>
  
  <p>I'm hoping to get all the texts from an xps document and put it on a rich text box.</p>