Date Format
Posted: Mon Apr 03, 2006 9:40 am
Hi Narcís Calvet,
I changed my bottom axis to double format and I could change the lable text. But once it finish all the formating then it change back to old format which is in double.
Please see my code below,
If (Axis = atBottom) Then
If Len(LabelText) > 0 Then
dTotValue = CDbl(LabelText)
If (dTotValue) >= 1 Then '' days
LabelText = Format((dTotValue), "###0") & " Days"
ElseIf (dTotValue * 24) >= 1 Then '' Hours
LabelText = Format((dTotValue * 24), "#0") & " Hours"
ElseIf (dTotValue * 24 * 60) >= 1 Then '' Minutes
LabelText = Format((dTotValue * 24 * 60), "#0") & " Min."
ElseIf (dTotValue * 24 * 60 * 60) >= 1 Then '' Sec
LabelText = Format((dTotValue * 24 * 60 * 60), "#0") & " Sec."
Else
LabelText = " 0 Sec."
End If
End If
End if
I changed my bottom axis to double format and I could change the lable text. But once it finish all the formating then it change back to old format which is in double.
Please see my code below,
If (Axis = atBottom) Then
If Len(LabelText) > 0 Then
dTotValue = CDbl(LabelText)
If (dTotValue) >= 1 Then '' days
LabelText = Format((dTotValue), "###0") & " Days"
ElseIf (dTotValue * 24) >= 1 Then '' Hours
LabelText = Format((dTotValue * 24), "#0") & " Hours"
ElseIf (dTotValue * 24 * 60) >= 1 Then '' Minutes
LabelText = Format((dTotValue * 24 * 60), "#0") & " Min."
ElseIf (dTotValue * 24 * 60 * 60) >= 1 Then '' Sec
LabelText = Format((dTotValue * 24 * 60 * 60), "#0") & " Sec."
Else
LabelText = " 0 Sec."
End If
End If
End if