Hi all
Ok I've written a little formula that I want to use to get hold of a filesize for display with a download link (i.e. download file now: 62kb).
This is the VB:
Public Shared Function getFileSize(ByVal filepath As String) As String
'creates the file object from the filepath specified
Dim file As New System.IO.FileInfo(filepath)
'returns the size in bytes of the file object and divides by 1024 to conver to kb
Return file.Length \ 1024 & "kb"
End Function
I then call it (with a test file):
<%=myFunctions.getFileSize("commonImages/pdf.png")%>
And get the er ...
Go to the complete details ...