![]() |
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-09-24 19:59 |
47,812 topics / 349,917 posts / today 0 new / 48,274 members |
| DOS批处理 & 脚本技术(批处理室) » Copy a file to the root directories of all specified disks, and it cannot be deleted |
| Printable Version 2,637 / 19 |
| Floor16 Kinglion | Posted 2007-03-07 05:32 |
| 铂金会员 Posts 1,924 Credits 5,798 From 金獅電腦軟體工作室 | |
|
After copying, you need to set the file attributes
|
|
| Floor17 zhoushijay | Posted 2007-03-07 08:55 |
| 高级用户 Posts 375 Credits 845 | |
|
If you want to be unable to delete, then embed it into the system process, such as explorer.exe, then it can't be deleted unless you also delete explorer. But this is恐怕 difficult with BAT...
|
|
| Floor18 g4rr | Posted 2007-03-08 08:56 |
| 初级用户 Posts 32 Credits 68 From 广东潮州 | |
|
I took a look at the code. Other things remain unchanged, just add a >nul 2>NUL after the COPY command. That is,
copy 21.bat %%i\ >nul 2>nul For the usage of NUL, you can refer to other posts in the forum. As for the ones that can't be deleted, I don't understand either. Wait for experts to reply! |
|
| Floor19 mfdcxnf | Posted 2007-03-10 04:18 |
| 初级用户 Posts 74 Credits 155 | |
|
What I verified on the 18th floor doesn't work, but I still thank you. Please help think of another way.
|
|
| Floor20 mfdcxnf | Posted 2007-03-10 04:41 |
| 初级用户 Posts 74 Credits 155 | |
|
How to load into the explorer.exe process.
|
|
| Prev 1 2 |
|
[ Contact the Union admin team -
中国DOS联盟 -
Standard version ] Sponsored by ifanr Inc | © 2001–2023 |