반응형 분류 전체보기778 XP에서 정품 혜택 알림 창 제거 참 쉽죠~잉 2012. 8. 29. CFileFind 사용법 변수/함수 선언. void SearchFolder(int &nItem, CString filename); CFileFindDlg(CWnd* pParent = NULL); // standard constructor bool m_bStop; CImageList m_img; CString m_strToken; BOOL m_bResult; enum { IDD = IDD_FILEFIND_DIALOG }; CListCtrlEx m_listResult; CButton m_btn_Serch; CButton m_btnStart; BOOL m_bSub; CString m_strFileLocation; CString m_strFileName; CString m_strStatus; 초기화 루틴. //--> 리스트 컨트롤에 이.. 2012. 8. 22. 스크롤바 꾸미기(색상표) Introduction Recently I needed a scroll bar that looked and acted like the one in Windows Media Player: The closest one I could find was the CSkinHorizontalScrollbarclass in Greg Ellis's article, but it did not support colors. So I createdXScrollBar, which has following features: Support for both horizontal and vertical scroll bars Optional color displayed on thumb and in channel Optional grippe.. 2012. 8. 21. GetLogicalDriveStrings() 현재 연결된 드라이브 이름 알아오기 원형 : GetLogicalDriveStrings(DWORD nBufferLength, LPTSTR lpBuffer) 예제 ) #include #include void main() { char buffer[256] = {0, }; LPCSTR temp; int n = 0; GetLogicalDriveStrings(256, buffer); while (buffer[n] != NULL) { for(int i = 0; i < sizeof(*(buffer+n));i++) { temp = buffer+n; n+=4; printf("%s 드라이브가 연결되어 있습니다. \n",temp); } } } 위와같이 코딩을 한 후 디버깅을 하면 아래와 같이 나온다. 즉 자료값이 들어가고나서 4번째번지마다 NULL값을 대입해서.. 2012. 8. 21. 하드 디스크 볼륨값 - GetVolumeInformation() 원형 : GetVolumeInformation(LPCTSTR lpRootPathName, LPTSTR lpVolumeNameBuffer, DWORD nVolumeNameSize, LPDWORD lpVolumeSerialNumber, LPDWORD lpMaximumComponentLength,LPDWORD lpFileSystemFlags,LPTSTR lpFileSystemNameBuffer,DWORD nFileSystemNameSize) 예제 ) #include #include using std::cout; using std::endl; void main() { char buffer[256] = {0, }; LPCSTR DrivePathName; int n = 0; char DriveName[100]; c.. 2012. 8. 21. 파일 속성 변경 - SetFileAttributes(); SetFileAttributes( m_LPCTSTR lpFileName , DWORD dwFileAttributes ); 특징 : 이함수는 해당파일의 속성을 변경하는건데 해당파일을 숨김파일이면 보이게 하거나 읽기전용 파일일때 체크를 해제하거나 할 수 있다. ~_~ 음... 아 그리고 windwos.h 를 인클루드 하면 사용이 가능하다. 예제 : #include SetFileAttributes("c:\\test.txt",FILE_ATTRIBUTE_HIDDEN); // "c:\test.txt 파일을 숨김파일로 변경한다. 부가설명 : 자주쓰는 2번째 인자값을 설명하자면 FILE_ATTRIBUTE_HIDDEN : 숨김파일로 FILE_ATTRIBUTE_NOMAL : 일반파일로 FILE_ATTRIBUTE_SYSTE.. 2012. 8. 21. 이전 1 ··· 35 36 37 38 39 40 41 ··· 130 다음 반응형