| | |
asp.net
Please support our ASP.NET advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Jul 2007
Posts: 24
Reputation:
Solved Threads: 0
•
•
•
•
I have a string storing some data i want to display that data on
a aspx page how should i do it??
Add a label control to your page, and name it for example Label1 then add the following code to your page_load event as bellow:
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
public partial class InsertRecord : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
string strVar = "Hello World";
Label1.Text = strVar.ToString();
Response.Write(strVar.ToString());
}
}
Regards,
Khaled
•
•
Join Date: Aug 2007
Posts: 14
Reputation:
Solved Threads: 0
Thanx for reply and this do work but my problem is that i retrieved some data from a excel sheet using oledb commands but and stored it in a string but the data in excel sheet has text that is bold,italics have super-script involved but when i display it on web/win form that bold,italics.....etc features vanishes and i dont know how to deal with this problem any ideas???
•
•
Join Date: Jul 2007
Posts: 24
Reputation:
Solved Threads: 0
•
•
•
•
Thanx for reply and this do work but my problem is that i retrieved some data from a excel sheet using oledb commands but and stored it in a string but the data in excel sheet has text that is bold,italics have super-script involved but when i display it on web/win form that bold,italics.....etc features vanishes and i dont know how to deal with this problem any ideas???
string strVar = "<b>Hello World</b>";
Label1.Text = strVar.ToString();
Response.Write(strVar.ToString());
Regards,
Khaled
![]() |
Similar Threads
- ASP.NET and Mozilla - Issues! (ASP.NET)
- Question for ASP.NET/Mozilla Users...or anyone... (ASP.NET)
- Newsgroups in ASP.NET forums??? (ASP.NET)
- ASP.Net hide site in the tray??? (ASP.NET)
- ASP.NET controls in Office 2003 style? (ASP.NET)
- .NET Speech SDK for ASP.NET (ASP.NET)
Other Threads in the ASP.NET Forum
- Previous Thread: Dropdown appears short in IE
- Next Thread: Data Base format in dotnet
Views: 1030 | Replies: 3
| Thread Tools | Search this Thread |
Tag cloud for ASP.NET
.net 2.0 activexcontrol advice ajax alltypeofvideos anathor application asp asp.net bc30451 bottomasp.net browser button c# checkbox click commonfunctions confirmationcodegeneration css dataaccesslayer database datagridview datagridviewcheckbox datalist deadlock development dgv dropdownlist dynamically edit editing expose feedback fill flash form formatdecimal formview google grid gridview iframe iis javascript list listbox login microsoft migration mono mouse mssql multistepregistration news numerical object objects opera panelmasterpagebuttoncontrols parent problem project radio registration reportemail richtextbox rotatepage rows save schoolproject search security session silverlight smartcard smoobjects software sql-server sqlserver2005 suse textbox tracking unauthorized update validation vb.net video videos view virtualdirectory vista visualstudio web webapplications webdevelopemnt webprogramming webservice xsl youareanotmemberofthedebuggerusers





