HTMLParser only converts the first line of the file

后端 未结 3 541
误落风尘
误落风尘 2021-01-15 15:32

I am using iText for .NET for converting HTML to PDF.
I\'m using HtmlParser to convert an HTML page to PDF, but the problem is that Htmlparser only seems to convert the

3条回答
  •  礼貌的吻别
    2021-01-15 16:14

    Error 1 Cannot implicitly convert type 'System.Collections.Generic.List' to 'System.Collections.ArrayList'

    Use it like this:

    List htmlarraylist = HTMLWorker.ParseToList(new StreamReader(tempFile),new StyleSheet());
                    foreach (IElement element in htmlarraylist)
                    {
                        document.Add(element);
                    }
    

提交回复
热议问题