|
本帖最后由 todaynew 于 2011-11-8 16:39 编辑
yanghua1900363 发表于 2011-11-8 15:44
'小写日期转大写
Function Date2Chinese(iDate As Date, iFormat As Byte) As String
'参数:iDate 指定日 ...
不需要这么多代码,呵呵。
Function strNew(strOld As String, str As String)
strOld = Replace(strOld, 0, "零")
For i = 1 To 9
strOld = Replace(strOld, i, Choose(i, "壹", "贰", "叁", "肆", "伍", "陆", "柒", "捌", "玖"))
Next
strOld = Replace(strOld, str, "年", 1, 1)
strOld = Replace(strOld, str, "月", 1, 1)
strOld = strOld & "日"
strNew = strOld
End Function
|
|