Search found 481 matches

by npocmaka_
05 Jul 2013 02:29
Forum: DOS Batch Forum
Topic: Need to check file size through batch script.
Replies: 1
Views: 1899

Re: Need to check file size through batch script.

Code: Select all

@echo off
if exist "filename" (
  for %%F in ("filename") do set "file_size=%%~zF"
)

if defined file_size if %file_size%0 NEQ 00  (
  do something
) else (
  do something else
)