i have using this function for the web-gui commponents
Shared Sub TextBox_LostFocus(ByRef pTextBox As TextBox, Optional ByVal NumDigitsAfterDecimal As Integer = 2, Optional ByVal err As ErrorProvider = Nothing)
If Not err Is Nothing Then
err.SetError(pTextBox, "")
End If
If pTextBox.Text.Trim.Length = 0 Then
pTextBox.Text = 0
End If
Try
pTextBox.Text = FormatNumber(pTextBox.Text, NumDigitsAfterDecimal)
pTextBox.Tag = pTextBox.Text
Catch ex As Exception
If Not err Is Nothing Then
err.SetError(pTextBox, "Incorrect Amount Format!")
End If
End Try
End Sub
but i am not be able to use the same function for the dev-express controls
plz help me to convert this code for use my dev-express controls
already i had try this code
Shared Sub ASPxTextBox_LostFocus(ByRef pTextBox As DevExpress.Web.ASPxEditors.ASPxTextBox, Optional ByVal NumDigitsAfterDecimal As Integer = 2, Optional ByVal err As DevExpress.ExpressApp.Web.Templates.Controls.ErrorInfoControl = Nothing)
If Not err Is Nothing Then
err.Caption = ""
End If
If pTextBox.Text.Trim.Length = 0 Then
pTextBox.Text = 0
End If
Try
pTextBox.Text = FormatNumber(pTextBox.Text, NumDigitsAfterDecimal)
Catch ex As Exception
If Not err Is Nothing Then
err.Caption = "Incorrect Amount Format!"
End If
End Try
End Sub
but it is not working.now plz help out me