You can read uploaded file inputsteam into a stream object then using streamreader read and append lines in a string builder at the end of loop display string builder content in a texbox like this:
<table>
<tr>
<td>
</td>
<td>
<asp:FileUpload ID="fileupload1" runat="server" />
</td>
</tr>
<tr>
<td>
</td>
<td>
<asp:Button ID="btnRead" runat="server" OnClick="btnRead_Click" Text="Read" />
</td>
</tr>
<tr>
<td valign="top">
Message of Created Text file :
</td>
<td>
<asp:TextBox ID="textBoxContents" runat="server" TabIndex="0" Height="380px" TextMode="MultiLine"
Width="367px"></asp:TextBox>
</td>
</tr>
</table>
protected void btnRead_Click(object sender, EventArgs e)
{
string path = fileupload1.PostedFile.FileName;
if (!string.IsNullOrEmpty(path))
{
Stream theStream = fileupload1.PostedFile.InputStream;
StringBuilder strbuild = new StringBuilder();
using (StreamReader sr = new StreamReader(theStream))
{
string line;
while ((line = sr.ReadLine()) != null)
{
strbuild.Append(line);
strbuild.AppendLine();
}
}
textBoxContents.Text = strbuild.ToString();
}
}