在DataColChanged事件中写入代码:
If e.DataCol.Name = "金额" Then
If e.NewValue >0 Then
Dim tx,tx1 As String
Dim s As String = Format( math.round(e.DataRow("金额")*100,0),"00000000000")
For i As Integer =0 To 10
Select Case s.SubString(i,1)
Case "0"
tx = "零"
Case "1"
tx = "壹"
Case "2"
tx = "贰"
Case "3"
tx = "叁"
Case "4"
tx = "肆"
Case "5"
tx = "伍"
Case "6"
tx = "陆"
Case "7"
tx = "柒"
Case "8"
tx = "捌"
Case "9"
tx = "玖"
End Select
tx1 = tx1 & tx
Next
e.DataRow("大写金额") = tx1
End If
End If
[此贴子已经被作者于2011-7-19 18:24:47编辑过]