How to dynamically load an .ascx with markup text from a file.

R

ronaldoveira

I have a to create a page that according the parameters it takes, it
has to read a .txt file from disk and display as the content. The .txt
file contains html text.

The display page is composed of a header, content and footer webuser
controls. The "content" user control is the one that should display the
content.

The firs idea I had was to simple setup a <p> and in server side fill
it with the value of the file. Well that didn't work that greate, since
the txt file already contains a lot of markup.
So, how can I "render" the txt file directly to the .ascx document ?
 
K

Ken Cox [Microsoft MVP]

How about inserting a Literal control and getting the text content into it?

Ken
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,754
Messages
2,569,521
Members
44,995
Latest member
PinupduzSap

Latest Threads

Top