19-12-16, 04:20 PM
19-12-16, 05:14 PM
CrystalReports
>Formula Fields
DataGridView
>Formula Fields
PHP كود :
if {Table1.Column1} < 0 then
"(" & ABS( {Table1.Column1} ) & ")"
else
ToText( {Table1.Column1} )
DataGridView
PHP كود :
Private Sub DataGridView1_CellFormatting(sender As Object, e As DataGridViewCellFormattingEventArgs) Handles DataGridView1.CellFormatting
If e.ColumnIndex = 1 AndAlso e.Value < 0 Then
e.Value = "(" & Math.Abs(e.Value) & ")"
End If
End Sub