본문 바로가기
IT-개발,DB

[개발] SHGetFolderPath 윈도우즈 특수 폴더 구하기

by SB리치퍼슨 2016. 4. 3.

SHGetFolderPath  윈도우즈 특수 폴더 구하기







다음은 특수 폴더 목록 샘플입니다.

 

Folder Name

Folder Path

CSIDL

CSIDL Name

Application Data

C:\Documents and Settings\Administrator\Application Data

0x1a

CSIDL_APPDATA

CD Burning

C:\Documents and Settings\Administrator\Local Settings\Application Data\Microsoft\CD Burning

0x3b

CSIDL_CDBURN_AREA

Common Administrative Tools

C:\Documents and Settings\All Users\Start Menu\Programs\Administrative Tools

0x2f

CSIDL_COMMON_ADMINTOOLS

Common Application Data

C:\Documents and Settings\All Users\Application Data

0x23

CSIDL_COMMON_APPDATA

Common Desktop

C:\Documents and Settings\All Users\Desktop

0x19

CSIDL_COMMON_DESKTOPDIRECTORY

Common Documents

C:\Documents and Settings\All Users\Documents

0x2e

CSIDL_COMMON_DOCUMENTS

Common Favorites

C:\Documents and Settings\All Users\Favorites

0x1f

CSIDL_COMMON_FAVORITES

Common Music

C:\Documents and Settings\All Users\Documents\My Music

0x35

CSIDL_COMMON_MUSIC

Common Pictures

C:\Documents and Settings\All Users\Documents\My Pictures

0x36

CSIDL_COMMON_PICTURES

Common Start Menu

C:\Documents and Settings\All Users\Start Menu

0x16

CSIDL_COMMON_STARTMENU

Common Start Menu Programs

C:\Documents and Settings\All Users\Start Menu\Programs

0x17

CSIDL_COMMON_PROGRAMS

Common Startup

C:\Documents and Settings\All Users\Start Menu\Programs\Startup

0x18

CSIDL_COMMON_STARTUP

Common Templates

C:\Documents and Settings\All Users\Templates

0x2d

CSIDL_COMMON_TEMPLATES

Common Video

C:\Documents and Settings\All Users\Documents\My Videos

0x37

CSIDL_COMMON_VIDEO

Cookies

C:\Documents and Settings\Administrator\Cookies

0x21

CSIDL_COOKIES

Desktop

C:\Documents and Settings\Administrator\Desktop

0x10

CSIDL_DESKTOPDIRECTORY

Favorites

C:\Documents and Settings\Administrator\Favorites

0x06

CSIDL_FAVORITES

Fonts

C:\WINDOWS\Fonts

0x14

CSIDL_FONTS

History

C:\Documents and Settings\Administrator\Local Settings\History

0x22

CSIDL_HISTORY

Local Application Data

C:\Documents and Settings\Administrator\Local Settings\Application Data

0x1c

CSIDL_LOCAL_APPDATA

My Documents

C:\Documents and Settings\Administrator\My Documents

0x05

CSIDL_PERSONAL

My Music

C:\Documents and Settings\Administrator\My Documents\My Music

0x0d

CSIDL_MYMUSIC

My Pictures

C:\Documents and Settings\Administrator\My Documents\My Pictures

0x27

CSIDL_MYPICTURES

NetHood

C:\Documents and Settings\Administrator\NetHood

0x13

CSIDL_NETHOOD

PrintHood

C:\Documents and Settings\Administrator\PrintHood

0x1b

CSIDL_PRINTHOOD

Profile Folder

C:\Documents and Settings\Administrator

0x28

CSIDL_PROFILE

Program Files

C:\Program Files

0x26

CSIDL_PROGRAM_FILES

Program Files - Common

C:\Program Files\Common Files

0x2b

CSIDL_PROGRAM_FILES_COMMON

Recent

C:\Documents and Settings\Administrator\Recent

0x08

CSIDL_RECENT

Send To

C:\Documents and Settings\Administrator\SendTo

0x09

CSIDL_SENDTO

Start Menu

C:\Documents and Settings\Administrator\Start Menu

0x0b

CSIDL_STARTMENU

Start Menu Programs

C:\Documents and Settings\Administrator\Start Menu\Programs

0x02

CSIDL_PROGRAMS

Startup

C:\Documents and Settings\Administrator\Start Menu\Programs\Startup

0x07

CSIDL_STARTUP

System Directory

C:\WINDOWS\system32

0x25

CSIDL_SYSTEM

Templates

C:\Documents and Settings\Administrator\Templates

0x15

CSIDL_TEMPLATES

Temporary Folder

C:\Documents and Settings\Administrator\Local Settings\Temp\

Temporary Internet Files

C:\Documents and Settings\Administrator\Local Settings\Temporary Internet Files

0x20

CSIDL_INTERNET_CACHE

Windows Directory

C:\WINDOWS

0x24

CSIDL_WINDOWS

 

명령 프롬프트 상태에서 명령어로 구동 시, 다음 목록의 스위치(switch)를 추가할 수 있습니다.

/stext <Filename>

Save the list of all special folders into a regular text file.

/stab <Filename>

Save the list of all special folders into a tab-delimited text file.

/scomma <Filename>

Save the list of all special folders into a comma-delimited text file (csv).

/stabular <Filename>

Save the list of all special folders into a tabular text file.

/shtml <Filename>

Save the list of all special folders into HTML file (Horizontal).

/sverhtml <Filename>

Save the list of all special folders into HTML file (Vertical).

/sxml <Filename>

Save the list of all special folders to XML file.

/sort <column>

This command-line option can be used with other save options for sorting by the desired column. If you don't specify this option, the list is sorted according to the last sort that you made from the user interface. The <column> parameter can specify the column index (0 for the first column, 1 for the second column, and so on) or the name of the column, like "Folder Name" and "Folder Path". You can specify the '~' prefix character (e.g: "~Folder Name") if you want to sort in descending order. You can put multiple /sort in the command-line if you want to sort by multiple columns.

Examples: 
SpecialFoldersView.exe /shtml "f:\temp\folders.html" /sort 2 /sort ~1 
SpecialFoldersView.exe /shtml "f:\temp\folders.html" /sort "Type" /sort "Name"

/nosort

When you specify this command-line option, the list will be saved without any sorting.





반응형

댓글