Created
February 15, 2019 06:47
-
-
Save TomoG29/26e28859d118404d07c3567d67276914 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private void TimeNow() | |
{ | |
DateTime now = DateTime.Now; | |
int year = now.Year; | |
//年 | |
int month = now.Month; | |
//月 | |
int day = now.Day; | |
//日 | |
int hour = now.Hour; | |
//時 | |
int minute = now.Minute; | |
//分 | |
int second = now.Second; | |
//秒 | |
int milisecond = now.Millisecond; | |
//ミリ秒 | |
DayOfWeek dayOfWeek = now.DayOfWeek; | |
//曜日 | |
//日曜日 = 0 ~ 土曜日 = 6 | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment