Function upper_HZ(amount)
On Error Resume Next
s_amount = CStr(Format(Abs(amount), "####.00"))
s_len = Len(s_amount)
s_amount = String(12 - s_len, "0") & s_amount
hz = num_to_hz(Mid(s_amount, 12, 1)) & "分整"
hz = num_to_hz(Mid(s_amount, 11, 1)) & "角" & hz
hz = num_to_hz(Mid(s_amount, 9, 1)) & "元" & hz
hz = num_to_hz(Mid(s_amount, 8, 1)) & "拾" & hz
hz = num_to_hz(Mid(s_amount, 7, 1)) & "佰" & hz
hz = num_to_hz(Mid(s_amount, 6, 1)) & "仟" & hz
hz = num_to_hz(Mid(s_amount, 5, 1)) & "万" & hz
hz = num_to_hz(Mid(s_amount, 4, 1)) & "拾" & hz
hz = num_to_hz(Mid(s_amount, 3, 1)) & "佰" & hz
hz = num_to_hz(Mid(s_amount, 2, 1)) & "仟" & hz
hz = num_to_hz(Mid(s_amount, 1, 1)) & "亿" & hz
hz = Right(hz, (s_len - 1) * 4 + 2)
upper_HZ = hz
End Function
我自己写的一个,没他们的好,用于发票上.