![]() |
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-13 01:15 |
47,811 topics / 349,897 posts / today 0 new / 48,256 members |
| DOS学习入门 & 精彩文章 (教学室) » [Help] A question for the batch file experts |
| Printable Version 645 / 3 |
| Floor1 kyolie | Posted 2003-10-02 00:00 |
| 初级用户 Posts 4 Credits 115 | |
|
How can I identify a file's extension in a batch file?
For example, I have 2 files, one is *.htm, the other is *.jpg. I want to delete the *.htm file — how do I identify the extension? |
|
| Floor2 huaqingyuan | Posted 2003-10-02 00:00 |
| 初级用户 Posts 15 Credits 183 | |
|
It seems just using
dEL *.htm is OK |
|
| Floor3 kyolie | Posted 2003-10-02 00:00 |
| 初级用户 Posts 4 Credits 115 | |
|
Thanks
|
|
| Floor4 GOTOmsdos | Posted 2003-12-06 00:00 |
| 铂金会员 Posts 1,827 Credits 5,154 | |
|
This seems like looking for the horse while sitting on it!
You've already written the extension in your question, so why are you still asking how to identify it? Can't you just type it in! Too strange! It's like asking, "Comrade Wang Weibing, what's your name?" Heh! The poster above didn't find it strange at all! He answered, "use del *.htm" — that's kind of like helping by saying, "Oh! You mean Wang Weibing! His name is Wang Weibing!" |
|
|
[ Contact the Union admin team -
中国DOS联盟 -
Standard version ] Sponsored by ifanr Inc | © 2001–2023 |