May 15, 2002 #1 BaDi Programmer May 14, 2002 32 0 0 NL Hi! How can I put the filesize of a file into a variable? Thanx in advance!
May 15, 2002 #2 CCLINT Programmer Feb 22, 2002 3,802 0 0 DE Use FSO (File System Object - reference to Microsoft Scripting), to get the file size, and set the return value to a variable. Dim oFso As New Scripting.FileSystemObject Dim f As Scripting.File Set f = oFso.GetFile("C:\myFile" Debug.Print f.Size Upvote 0 Downvote
Use FSO (File System Object - reference to Microsoft Scripting), to get the file size, and set the return value to a variable. Dim oFso As New Scripting.FileSystemObject Dim f As Scripting.File Set f = oFso.GetFile("C:\myFile" Debug.Print f.Size
May 15, 2002 #3 JustinEzequiel Programmer Jul 30, 2001 1,192 0 0 PH alternative... Code: x = FileLen("C:\WINDOWS\win.com") Upvote 0 Downvote