title: VBS: How to get the filesize with special FileDialog?
body: <pre><code>Function FileDialog() 
    Dim oExec1: Set oExec1=CreateObject("WScript.Shell").Exec( "mshta.exe ""about:" &amp; "&lt;" &amp; "input type=file id=FILE" &amp; "&gt;" &amp; "&lt;" &amp; "script&gt;FILE.click();new ActiveXObject('Scripting.FileSystemObject').GetStandardStream(1).WriteLine(FILE.value);close();resizeTo(0,0);" &amp; "&lt;" &amp; "/script&gt;""" )
    Dim sPathfile: sPathfile = oExec1.StdOut.ReadAll
    sPathfile = Replace( sPathfile, vbCRLF, "" )
    FileDialog = sPathfile
  End Function
  </code></pre>
  
  <p>change to:
  Function FileDialog(filesize) </p>
  
  <p>filesize will return the value of bytes of the selected file</p>