I used a batch file to make changes to a desktop.ini file by replacing the existing one with a new one. The code for this part is:
move /y "Games\desktop.ini" "%UserProfile%\Games"
It manages to successfully replace the file (I used attrib +s and +h) but the folder's icon doesn't change. What can I do to make Windows Explorer recognize the change? I heard something about SHChangeNotify before.
I figured it out, it was so simple. All I had to do was this:
attrib +s +r "%UserProfile%\Games"
Icon changed instantly.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.