Private Function fSize(ByVal oSize As Double)
Dim mySize As String = ""
If oSize < 1024 Then
mySize = Format(oSize, "#,##0.00") & " Bt"
Else
If (oSize / 1024) < 1024 Then
mySize = Format((oSize / 1024), "#,##0.00") & " Kb"
Else
If (oSize / 1024 / 1024) < 1024 Then
mySize = Format((oSize / 1024 / 1024), "#,##0.00") & " Mb"
Else
mySize = Format((oSize / 1024 / 1024 / 1024), "#,##0.00") & " Gb"
End If
End If
End If
Return mySize
End Function
ไม่มีความคิดเห็น:
แสดงความคิดเห็น