Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

long date time format in c# asp.net (or) datetime format in c#



In this post , I explained how to display date and time in windows application, date and time displayed in label controls


using System;
usingSystem.Collections.Generic;
usingSystem.ComponentModel;
usingSystem.Data;
usingSystem.Drawing;
usingSystem.Text;
usingSystem.Windows.Forms;
usingTelerik.WinControls;

namespace company
{
    public partial class Receipts : Telerik.WinControls.UI.RadForm
    {
        publicReceipts()
        {
            InitializeComponent();
        }

        privatevoid Receipts_Load(objectsender, EventArgs e)
        {
            lbldate.Text = DateTime.Now.ToLongDateString();
            lblTime.Text = DateTime.Now.ToLongTimeString().ToString();
        }

        privatevoid timer1_Tick(objectsender, EventArgs e)
        {
            lblTime.Text = DateTime.Now.ToLongTimeString().ToString();
        }
    }
}




This post first appeared on Asp.netSourceCodes, please read the originial post: here

Share the post

long date time format in c# asp.net (or) datetime format in c#

×

Subscribe to Asp.netsourcecodes

Get updates delivered right to your inbox!

Thank you for your subscription

×