ASP.NET (Date and Time)
#Basic Info Before Making Project
1.Button- it is onclick event
Convert.tosingle - float
Convert.tostring – string
#Make New Project For Date Time in Asp.net
#Open Visual Studio 2017
- File >New project >Visual C# click on >web > asp.net web app > empty
- Then click on view > Solution explorer
- Then right click on web application > add new item> web form
- Click on Design
- . Type anything and run in any browser
1. Push button
2. Link button
3. Image button
# Label control – read only
·
Click on view> toolbox> label
· Add 2 label
Label.Text=”Anyname”; [save]
Label2.Text = DateTime.Now.ToString();
[for date]
public partial class Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
Label2.Text =
DateTime.Now.ToString();
Label1.Text = 100.ToString();
}
|
Label1.Text = 100.ToString();
To convert integer into string
No comments:
Post a Comment