.作者: q741230412 时间: 2015-4-19 07:46 作者: kelejiabing101 时间: 2015-4-20 22:50
源码较短作者: 26666180 时间: 2015-4-21 01:19
.........................作者: 574221329 时间: 2015-4-21 01:39
认真回复 好好学习作者: 墨染年华 时间: 2015-4-21 20:20
学习一下。作者: _简简单单_ 时间: 2015-4-22 14:05 赞作者: jushunhe 时间: 2015-4-23 13:45
取格式文件大小作者: warcraftii 时间: 2015-4-23 22:27
wRemoveMsg
[in] Specifies how messages are handled. This parameter can be one of the following values. Value Meaning
PM_NOREMOVE Messages are not removed from the queue after processing by PeekMessage.
PM_REMOVE Messages are removed from the queue after processing by PeekMessage.
You can optionally combine the value PM_NOYIELD with either PM_NOREMOVE or PM_REMOVE. This flag prevents the system from releasing any thread that is waiting for the caller to go idle (see WaitForInputIdle).
有一个缺点,假如文件正在运行(例如进程文件),就无法获取了。这样写会更好:
function GetFileSize()
var Path=filedialog(1,"All File|*.*")
var fso=com("Scripting.FileSystemObject")
var objFile = fso.GetFile(Path)
return objFile.Size
end
//函数调用:
function button0_click()
messagebox(GetFileSize())
end