嘿,亲!知识可是无价之宝呢,但咱这精心整理的资料也耗费了不少心血呀。小小地破费一下,绝对物超所值哦!如有下载和支付问题,请联系我们QQ(微信同号):813200300
本次赞助数额为: 2 元微信扫码支付:2 元
请留下您的邮箱,我们将在2小时内将文件发到您的邮箱
C#生成生辰八字
public static string[] date = {
"甲子", "乙丑", "丙寅", "丁卯", "戊辰", "己巳", "庚午", "辛未", "壬申", "癸酉",
"甲戊", "乙亥", "丙子", "丁丑", "戊寅", "乙卯", "庚辰", "辛巳", "壬午", "癸未",
"甲申", "乙酉", "丙戌", "丁亥", "戊子", "己丑", "庚寅", "辛卯", "壬辰", "癸巳",
"甲午", "乙未", "丙申", "丁酉", "戊戌", "己亥", "庚子", "辛丑", "壬寅", "癸卯",
"甲辰", "乙巳", "丙午", "丁未", "戊申", "乙酉", "庚戌", "辛亥", "壬子", "癸丑",
"甲寅", "乙卯", "丙辰", "丁巳", "戊午", "己未", "庚申", "辛酉", "壬戌", "癸亥"
};
public int yearZi=0;
private void btnOk_Click(object sender, EventArgs e)
{
DateTime dt=Day.Value;
int year=dt.Year;
int moon = dt.Month;
int date = dt.DayOfYear;
MessageBox.Show("Test:" (year%60-3) ":" moon ":" date);
//调用获得年生辰的方法
String yearZi = yearZ(year);
string moonZi = moonZ(moon,year);
string dayZi = dayei(year, date);
int hour = int.Parse(hourDate.Text);
string hourZi= Hours(hour, date, year);
txtBrithday.Text = yearZi " " moonZi " " dayZi " " hourZi;
}