title: Getting exception while using itextsharp to convert from html to pdf in web api
body: <p>List item</p>
  
  <p>I am getting <code>"the uri prefix is not recognized itextsharp"</code></p>
  
  <p>Exception. Following the method of my web api controller. which receives the html data and converting it to pdf.</p>
  
  <pre><code>[System.Web.Http.AcceptVerbs("GET", "POST")]
      public HttpResponseMessage DownloadPDF(long estimationId)
      {  
  
     HttpResponseMessage result = new HttpResponseMessage(HttpStatusCode.OK);      
           try
          {
  //Method fetch the data for estimationId and convert that to HTML
              string html = objRepository.GetHTML(estimationId);
  
              //Create PDF
              var document = new iTextSharp.text.Document(PageSize.A4);
              document.SetMargins(20.0F, 20.0F, document.TopMargin + 20, document.BottomMargin);
              var output = new MemoryStream();
              var writer = PdfWriter.GetInstance(document, output);
              document.Open();
              StringReader strRdr = new StringReader(html);
              var parsedHtmlElements = HTMLWorker.ParseToList(strRdr, null);
              foreach (var htmlElement in parsedHtmlElements)
                  document.Add(htmlElement as IElement);
              writer.CloseStream = false;
              writer.Flush();
             // document.Close();
              output.Seek(0, SeekOrigin.Begin);
  
              result.Content = new ByteArrayContent(output.ToArray());
          }
          catch (Exception e)
          {
              ErrorLog.GetDefault(System.Web.HttpContext.Current).Log(new Error(e));
          }
          return result;
      }
  </code></pre>
  
  <p>Exception occurred at line </p>
  
  <pre><code>   var parsedHtmlElements = HTMLWorker.ParseToList(strRdr, null); 
  </code></pre>
  
  <p>Any help please. </p>