| | |
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
| Thread Tools | Search this Thread |
.net 2.0 activexcontrol advice ajax alltypeofvideos asp asp.net bc30451 bottomasp.net browser businesslogiclayer button c# c#gridviewcolumn checkbox click commonfunctions compatible confirmationcodegeneration content contenttype courier css dataaccesslayer database datagridview datagridviewcheckbox datalist deadlock development dgv dropdownlist dropdownmenu dynamically edit expose fill flash flv formatdecimal forms formview gridview homeedition iframe iis javascript jquery listbox login menu microsoft mono mouse mssql multistepregistration news numerical objects opera order panelmasterpagebuttoncontrols radio ratings registration reportemail rotatepage save schoolproject search security serializesmo.table silverlight smartcard smoobjects software sql-server sqlserver2005 suse textbox tracking unauthorized validation vb.net video videos virtualdirectory vista visual-studio visualstudio web webapplications webarchitecture webdevelopemnt webprogramming webservice xml xsl youareanotmemberofthedebuggerusers





