IT Process Automation

 View Only

CA PAM::.Javascript::. getDay() Method 

Mar 23, 2017 10:53 AM

getDay()

 

Overview - definition

 

Returns the day of the week (from 0-6)

 

Usage

The getDay() method returns the day of the week (from 0 to 6) for the specified date.

  • 0
    • Sunday
  • 1
    • Monday
  • 2
    • Tuesday
  • 3
    • Wednesday
  • 4
    • Thursday
  • 5
    • Friday
  • 6
    • Saturday

 

 

Results

A Number, from 0 to 6, representing the day of the week

Examples

 

var vDate = new Date();
var vWeekDay = vDate.getDay();

 

var vdate = new Date();

var weekday = new Array(7);
weekday[0] =  "Sunday";
weekday[1] = "Monday";
weekday[2] = "Tuesday";
weekday[3] = "Wednesday";
weekday[4] = "Thursday";
weekday[5] = "Friday";
weekday[6] = "Saturday";

var vWeekDayName = weekday[vdate.getDay()];

 

 

var vdate = new Date();

var weekday = new Array(7);
weekday[0] =  "Domingo";
weekday[1] = "Segunda-feira";
weekday[2] = "Terça-feira";
weekday[3] = "Quarta-feira";
weekday[4] = "Quinta-feira";
weekday[5] = "Sexta-feira";
weekday[6] = "Sabado";

var vWeekDayName = weekday[vdate.getDay()];

 

 

know_more.png

Summary CA Process Automation 

Summary CA Service Management Community 

Service Desk Manager 15 days Implementation 

CABI:: Summary - BOXI for CA SDM 

Summary CA SDM Scoreboard 

 

 

Was useful, please leave your feedback!

Statistics
0 Favorited
0 Views
0 Files
0 Shares
0 Downloads

Tags and Keywords

Related Entries and Links

No Related Resource entered.