Where is the guideline that says you shouldn't write to the Program Files area?

前端 未结 2 1425
别跟我提以往
别跟我提以往 2021-02-05 18:20

Many questions on SO say \"Windows developer guidelines\" or \"windows design guidelines\" say that you shouldn\'t write temporary or program data to the Program Files area, but

2条回答
  •  迷失自我
    2021-02-05 18:51

    In later versions of windows (Vista, 7 and of course server versions) access permission are restricted for "special folders" including "Program Files". Even if your program is elevated to have sufficient privileges to write to this folder it is still a bad idea.

    I don't know of any guidelines that state this but there is a list of special folders and what they are meant for. The fact that there is a special folder for nearly all types of data I can image means there is no need to use the program files folder.Special Folders list

提交回复
热议问题