中国DOS联盟论坛

China DOS Union

-- Unite DOS · Advance DOS · Grow DOS --
Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
Guest | Log in | Register | Members | Search | China DOS Union
中国DOS联盟论坛
The time now is 2026-08-12 14:10
47,811 topics / 349,897 posts / today 0 new / 48,256 members
DOS媒体世界 & 网络技术 (多媒体室) » 请问在bat文件中如何判断映射服务器的存在? Translated: How to determine the existence of a mapped server in a bat file?
Printable Version  1,858 / 1
Floor1 stonewall Posted 2005-10-10 11:23
初级用户 Posts 3 Credits 22
Dear experts:
Little brother is asking about a problem related to NET USE.

I know that the NET USE command can be used under the DOS command line to retrieve mapped drive information.

But, how to judge the existence of this mapped information in a bat file?

For example: using the following command
NET USE S: \\192.168.1.169\sharefolder /user:sss ppp
to create a mapped drive, then how to judge the existence of drive S in the bat file?

Thanks for everyone's help!
Floor2 ragingfire Posted 2010-06-09 11:48
新手上路 Posts 2 Credits 3
Try to `cd` to the drive letter, and then use `if` to judge
[ Contact the Union admin team - 中国DOS联盟 - Standard version ]
Sponsored by ifanr Inc | © 2001–2023