Search code examples
c#asp.nethtml-helperwebforms

How to display HTML file inside ASP.NET Webform


I have an embed device which is returning back info in HTML files, Now I trying to make ASP.NET webform application, so end users can see these logs. What is proper way to open HTML file at local server and display inside webform.


Solution

  • If they are complete HTML files (including <html> and <body> tags) then it's probably best to show them in a Frame. Are they in a location you can create an URL for?

    For html fragments you'll have to load them in code-behind and show them in for example a Literal control.