asp貨幣大寫轉(zhuǎn)換函數(shù)(2)_ASP教程
教程Tag:暫無Tag,歡迎添加,賺取U幣!
推薦:怎樣限制只能中文輸入的方法。function isCharsInBag (s, bag) { var i,c; for (i = 0; i s.length; i++) { c = s.charAt(i);//字符串s中的字符 if (bag.indexOf(c) -1) return c; } return ; } 檢查函數(shù): function ischinese(s) { var errorChar; var badChar = ABCDEFGHIJKLMNOPQRST
If nZero <> 0 Or I = J - 9 Or I = J - 5 Or I = J - 1 Then
If Right(AtoC, 1) = "零" Then AtoC = Left(AtoC, Len(AtoC) - 1)
Ch1 = "零"
Else
Ch1 = ""
End If
'如果轉(zhuǎn)換的數(shù)值需要擴大,那么需改動以下表達(dá)式 I 的值。
If I = J - 10 Then
Ch2 = "億"
ElseIf I = J - 6 Then
If nZero <> 0 Then
Ch2 = "萬"
' nZero = 0
End If
ElseIf I = J - 2 Then
Ch2 = "元"
ElseIf I = J Then
Ch2 = "整"
Else
Ch2 = ""
End If
nZero = 0
End If
AtoC = AtoC & Ch1 & Ch2
Next I
'最后將多余的零去掉
AtoC = Replace(AtoC, "零元", "元")
AtoC = Replace(AtoC, "零萬", "萬")
AtoC = Replace(AtoC, "零億", "億")
AtoC = Replace(AtoC, "零整", "整")
分享:ASP編程中15個非常有用的例子(二)8.強迫輸入密碼對話框 答把這句話放載頁面的開頭 % response.status=401 not Authorized response.end % 9 如何傳遞變量從一頁到另一頁 答 用HIDDEN類型來傳遞變量 % form method=post action=mynextpage.asp % for each item in request.form % input
相關(guān)ASP教程:
- asp FSO 讀寫文件本文件實現(xiàn)代碼
- asp中isNull、isEmpty和空字符串的區(qū)別
- asp獲取用戶真實IP地址的方法
- asp連接sqlserver數(shù)據(jù)庫實現(xiàn)代碼
- asp中正則表達(dá)式過濾html代碼函數(shù)
- asp中g(shù)et post提交表單區(qū)別
- 網(wǎng)頁模板:ASP內(nèi)建對象Request
- xmlhttp的open方法使用詳解
- ASP的常用的自定義函數(shù)大全
- asp中用for循環(huán)的一個小技巧
- eWebEditor v3.8 列目錄
- ASP無組件分頁實現(xiàn)思路及代碼
- 相關(guān)鏈接:
- 教程說明:
ASP教程-asp貨幣大寫轉(zhuǎn)換函數(shù)(2)
。