C:\>Type nul>file C:\>Mkdir folder C:\>dir /ad file.txt>nul 2>&1 || Echo.file is not folder. file is not folder. C:\>dir /ad /b folder>nul 2>&1 && Echo.folder is folder. folder is folder. C:\>