各位老大,帮忙做个测试呗
测试代码:程序代码:
DECLARE CovertLunarToSolar IN dlltest.dll INTEGER iyear,INTEGER imonth,INTEGER iday,INTEGER @iyear,INTEGER @imonth,INTEGER @iday &&农历转阳历 DECLARE GetLunarDate IN dlltest.dll INTEGER iyear,INTEGER imonth,INTEGER iday,INTEGER @iyear,INTEGER @imonth,INTEGER @iday &&阳历转阴历 DECLARE INTEGER CalcDateDiff IN dlltest.dll INTEGER iyear,INTEGER imonth,INTEGER iday,INTEGER iyear,INTEGER imonth,INTEGER iday &&计算日期差 DECLARE FormatLunarYear IN dlltest.dll INTEGER iyear,STRING @buffer &&格式化阴历的year DECLARE FormatMonth IN dlltest.dll INTEGER imonth,STRING @buffer &&格式化阴历的month DECLARE FormatLunarDay IN dlltest.dll INTEGER iday,STRING @buffer &&格式化阴历的day &&函数声明结束 clear year1=0 month1=0 day1=0 ybuffer=space(10) mbuffer=space(4) dbuffer=space(8) GetLunarDate(2013,01,07,@year1,@month1,@day1) FormatLunarYear(year1,@ybuffer) FormatMonth(month1,@mbuffer) FormatLunarDay(day1,@dbuffer) ?'转换后的阴历日期是'+ybuffer+mbuffer+dbuffer CovertLunarToSolar(2012,12,23,@year1,@month1,@day1) ?'我的阳历生日是'+str(year1,4,0)+'年'+str(month1,2,0)+'月'+str(day1,2,0)+'日' idays=CalcDateDiff(year1,month1,day1,year(date()),month(date()),day(date())) ?'我还有'+str(idays,3,0)+'天就过生日了' [local]1[/local]
[ 本帖最后由 wp231957 于 2013-1-7 12:06 编辑 ]
dlltest.rar
(228.36 KB)