6

How I could check if network folder shared exists using batch script?

Example: \\10.10.10.1\folder1\folder2\shared_folder

Stephane
  • 6,432
  • 3
  • 26
  • 47
gedO
  • 267
  • 1
  • 4
  • 12

2 Answers2

5

if exist \\10.10.10.1\folder1\folder2\shared_folder echo It's here

Stephane
  • 6,432
  • 3
  • 26
  • 47
0

A another option that will keep your script from hanging on a down system:

 ping -n 1 %1 >nul && if exist \\10.10.10.1\folder1\folder2\shared_folder echo It's here
Mike Q
  • 163
  • 1
  • 4