Click here to Skip to main content
15,898,222 members
Home / Discussions / ASP.NET
   

ASP.NET

 
Questionloginname control Pin
mylogics11-Aug-09 23:52
professionalmylogics11-Aug-09 23:52 
AnswerRe: loginname control Pin
Abhishek Sur12-Aug-09 0:26
professionalAbhishek Sur12-Aug-09 0:26 
QuestionDigital clock Pin
kavinnagarajan11-Aug-09 23:23
kavinnagarajan11-Aug-09 23:23 
AnswerRe: Digital clock Pin
Sun Rays11-Aug-09 23:38
Sun Rays11-Aug-09 23:38 
AnswerRe: Digital clock Pin
Abhijit Jana11-Aug-09 23:43
professionalAbhijit Jana11-Aug-09 23:43 
GeneralDigital clock Pin
kavinnagarajan11-Aug-09 23:47
kavinnagarajan11-Aug-09 23:47 
GeneralRe: Digital clock Pin
Abhijit Jana11-Aug-09 23:56
professionalAbhijit Jana11-Aug-09 23:56 
GeneralRe: Digital clock Pin
Abhishek Sur12-Aug-09 0:32
professionalAbhishek Sur12-Aug-09 0:32 
place the javascript function in your masterpage

var clock;
 
function stopClock(){
  clearTimeout(clock);
}
 
function yourClock(){
  var nd = new Date();
  var h, m;
  var s;
  var time = " ";
  h = nd.getHours();
  m = nd.getMinutes();
  s = nd.getSeconds();
  if (h <= 9) h = "0" + h;
  if (m <= 9) m = "0" + m;
  if (s <= 9) s = "0" + s;
  time += h + ":" + m + ":" + s;
  document.getElementbyId('yourclockbox').value = time;
  clock = setTimeout("yourClock()", 1000);
}


Now in body tag of your masterpage use :

<BODY onLoad="yourClock()", onUnload="stopClock(); return true">

Place one div named yourclockbox in your page. Apply proper CSS. You are done... Thumbs Up | :thumbsup: Thumbs Up | :thumbsup:

Abhishek Sur

My Latest Articles
Create CLR objects in SQL Server 2005
C# Uncommon Keywords
Read/Write Excel using OleDB

Don't forget to click "Good Answer" if you like to.

GeneralDigital clock Pin
kavinnagarajan12-Aug-09 0:45
kavinnagarajan12-Aug-09 0:45 
GeneralRe: Digital clock Pin
Abhishek Sur12-Aug-09 1:55
professionalAbhishek Sur12-Aug-09 1:55 
QuestionMasterpage Vs Content page Pin
kavinnagarajan11-Aug-09 23:09
kavinnagarajan11-Aug-09 23:09 
AnswerRe: Masterpage Vs Content page Pin
Abhijit Jana11-Aug-09 23:15
professionalAbhijit Jana11-Aug-09 23:15 
QuestionUsing Ajax Cascading dropdown with sql stored procedures Pin
Andile.M11-Aug-09 22:39
Andile.M11-Aug-09 22:39 
AnswerRe: Using Ajax Cascading dropdown with sql stored procedures Pin
keyur satyadev11-Aug-09 22:47
keyur satyadev11-Aug-09 22:47 
GeneralRe: Using Ajax Cascading dropdown with sql stored procedures Pin
Andile.M12-Aug-09 6:32
Andile.M12-Aug-09 6:32 
QuestionHow to get full path from fileupload control or every thing from client side? [modified] Pin
Saba0211-Aug-09 22:21
Saba0211-Aug-09 22:21 
AnswerRe: How to get full path from fileupload control or every thing from client side? Pin
Abhijit Jana11-Aug-09 22:23
professionalAbhijit Jana11-Aug-09 22:23 
GeneralRe: How to get full path from fileupload control or every thing from client side? Pin
Saba0211-Aug-09 22:35
Saba0211-Aug-09 22:35 
AnswerRe: How to get full path from fileupload control or every thing from client side? Pin
keyur satyadev11-Aug-09 22:59
keyur satyadev11-Aug-09 22:59 
GeneralRe: How to get full path from fileupload control or every thing from client side? Pin
Saba0211-Aug-09 23:07
Saba0211-Aug-09 23:07 
GeneralRe: How to get full path from fileupload control or every thing from client side? Pin
Abhijit Jana11-Aug-09 23:08
professionalAbhijit Jana11-Aug-09 23:08 
GeneralRe: How to get full path from fileupload control or every thing from client side? Pin
Saba0211-Aug-09 23:14
Saba0211-Aug-09 23:14 
QuestionCSV files Pin
dotnetmember11-Aug-09 22:06
dotnetmember11-Aug-09 22:06 
AnswerRe: CSV files Pin
r a m e s h11-Aug-09 22:20
r a m e s h11-Aug-09 22:20 
AnswerRe: CSV files Pin
Abhishek Sur12-Aug-09 0:45
professionalAbhishek Sur12-Aug-09 0:45 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.