Digital turn amount in VB

xiaoxiao2021-03-06  42

'// * function: amount lowercase conversion to capital call parameters: jesj ... RMB lowercase amount' // * Return Variable: name .. RMB Capital amount public function fun_jezh (jesj as double) AS STRING DIM Name1 $, Name2 $ , MJE1 $, Name $ DIM LEN_MJE1%, K%, WS%, J%, WS1%, M% Dim Bz as boolean name1 = "壹 贰 伍 柒捌" Name2 = "Person Wan Qi 100 million "MJE1 = Trim (Format (Jesj," ###. 00 "))) LEN_MJE1 = LEN (MJE1) if len_mje1> 16 or jesj <0.01 or isnull (jesj) THEN FUN_JEZH =" " EXIT FUNCTION END IF '// Nothing Small String MJE1 = Left (MJE1, LEN_MJE1 - 3) Right (MJE1, 2) LEN_MJE1 = LEN_MJE1 - 1 K = LEN_MJE1 * 2 - 1 WS = Int (MID (MID (MJE1, 1, 1)) * 2 - 1

If len_mje1 = 3 and WS <0 THEN '// If the amount <1 Name =' 'Name = "" Else IF WS> 0 Then Name = MIDB (Name1, WS, 2) MIDB (Name2, K, 2)' // If the amount> = 1, conversion amount end if end if j = 2 k = k - 2 bz = truexh1: do while j <= len_mje1 and bz WS1 = int (MID (MID (MID (MJE1, J, 1)) * 2 - 1 IF WS1> 0 THEN Name = Name MIDB (Name1, WS1, 2) MIDB (Name2, K, 2) J = J 1 K = K - 2 Goto XH1 End IF M = 0xH2: do while WS1 <0 If len_mje1> = 11 THEN IF K <21 THEN M = M 1 end if End if IF k = 5 OR (k = 13 and m <= 3) OR K = 21 THEN Name = Name MIDB (Name2, K, 2) End if if k = 1 Then name = name "whole" bz = false exit do end if j = j 1 k = k - 2 ws1 = int (MID (MJE1, J, 1)) * 2 - 1 IF WS1 <0 THEN GOTO XH2 ELSE IF LEN_MJE1 = 3 THEN Name = Name "Zero" Else Name = Name "Zero" End If End If LOOP LOOP

= = 元 元 和 和 (1230.32) WZ1 = INSTR (1, Name, "Yuan") WZ2 = INSTR (1, Name, "Corner") IF WZ1 <> 0 and WZ2 <> 0 THEN WZ3 = INSTR WZ1, NAME, "Zero") IF WZ3 <> 0 Then Name = MID (Name, 1, WZ3 - 1) MID (Name, WZ3 1, Len (Name)) end if end if fun_jezh = nameEnd function

转载请注明原文地址:https://www.9cbs.com/read-52997.html

New Post(0)