천객만래 [千客萬來] (It has an interminable succession of visitors)

수의 파일명을 한번에 변경하기


촬영 사진이나 앨범 또는 다운로드 받은 이미지의 이름을 한번에 바꾸는데 필요한 팁입니다.

저의 경우 촬영한 사진을 정리하는데, 촬영한 사진파일에 촬영장소나 정보로 보관하기 쉽게 파일에 이름을 정해서 보관하고 있습니다.  그런데 한개 한개 파일에 이름을 변경하려고 하니까 엄청난 노가다가 아니더군요.. 

그런데 우연하게 여러개의 파일을 한번에 변경하는 방법을 알게 되었습니다.

아시는 분은 이미 알고 계시겠지만, 저 처럼 그동안 이 방법을 모르고 계시는 분들을 위해서 팁으로 올려 봅니다.

일단 변경하고자 하는 파일을 모두 선택합니다.

그리고 첫번 째 파일의 이름을 변경합니다. 

다음 엔터를 치면은 아래와 같이 선택했던 파일들이 순번이 정해져서 지정했던 파일 명으로 변경됩니다



변경하려는 파일명을 "family" 라고 변경하고 엔터를 치면


나머지 파일들은 다음과 같이 변경된다.


사용자가 변경한 파일명

family.jpg


자동으로 변경되는 파일명들


family (1).jpg

family (2).jpg

family (3).jpg

family (4).jpg

family (5).jpg

Posted by SB패밀리

마이크로소프트웨어의 커버 스토리 "개발자를 위한 크로스플랫폼 개발 전략" 중

델파이로 보는 레거시 환경에서의 크로스플랫폼 지원 기사입니다.








Posted by SB패밀리

윈도우즈에서 실행중인 프로세스를 강제 종료시키자.
내가 사용하는 방법도 있지만 아래 소스가 잘 정리되어 있어서 그대로 스크랩했다.



출처 : http://koronaii.tistory.com/241

BOOL CGomControl::ProcessKill(CString strProcessName)                                                                       
{                                                                                                                                                           
   HANDLE hProcessSnap = NULL;                                                                                                          
   BOOL bRet = FALSE;                                                                                                                          
   PROCESSENTRY32 pe32 = {0};                                                                                                          
                                                                                                                                                           
   hProcessSnap = CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, 0);                                              
   if (hProcessSnap == (HANDLE)-1)                                                                                                       
       return false;                                                                                                                                  
   pe32.dwSize = sizeof(PROCESSENTRY32);                                                                                          
                                                                                                                                                           
   //프로세스가 메모리상에 있으면 첫번째 프로세스를 얻는다                                                                        
   if (Process32First(hProcessSnap, &pe32))                                                                                            
   {                                                                                                                                                      
       BOOL bCurrent = FALSE;                                                                                                               
       MODULEENTRY32 me32 = {0};                                                                                                       
                                                                                                                                                           
       do {                                                                                                                                             
           bCurrent = GetProcessModule(pe32.th32ProcessID,strProcessName);                                            
           if(bCurrent) {                                                                                                                            
               HANDLE hProcess = OpenProcess(PROCESS_ALL_ACCESS, FALSE, pe32.th32ProcessID);           
               if(hProcess) {                                                                                                                        
                   if(TerminateProcess(hProcess, 0)) {                                                                                    
                       unsigned long nCode; //프로세스 종료 상태                                                                       
                       GetExitCodeProcess(hProcess, &nCode);                                                                         
                   }                                                                                                                                      
                   CloseHandle(hProcess);                                                                                                     
               }                                                                                                                                          
           }                                                                                                                                              
       }                                                                                                                                                  
       //다음 프로세스의 정보를 구하여 있으면 루프를 돈다.                                                                           
       while (Process32Next(hProcessSnap, &pe32));                                                                                 
   }                                                                                                                                                      
                                                                                                                                                           
   CloseHandle (hProcessSnap);                                                                                                             
   return true;                                                                                                                                       
}                                                                                                                                                           
  
                                                                                                                                                         
BOOL CGomControl::GetProcessModule(DWORD dwPID, CString sProcessName)                                        
{                                                                                                                                                           
   HANDLE hModuleSnap = NULL;                                                                                                           
   MODULEENTRY32 me32 = {0};                                                                                                           
                                                                                                                                                           
   hModuleSnap = CreateToolhelp32Snapshot(TH32CS_SNAPMODULE, dwPID);                                          
   if(hModuleSnap == (HANDLE)-1)                                                                                                         
       return (FALSE);                                                                                                                             
   me32.dwSize = sizeof(MODULEENTRY32);                                                                                           
                                                                                                                                                           
   //해당 프로세스의 모듈리스트를 루프로 돌려서 프로세스이름과 동일하면                                                     
   //true를 리턴한다.                                                                                                                              
   if(Module32First(hModuleSnap, &me32)) {                                                                                           
       do {                                                                                                                                             
           if(me32.szModule == sProcessName)                                                                                          
           {                                                                                                                                              
               CloseHandle (hModuleSnap);                                                                                                  
               return true;                                                                                                                           
           }                                                                                                                                              
       }                                                                                                                                                  
                                                                                                                                                           
       while(Module32Next(hModuleSnap, &me32));                                                                                   
   }                                                                                                                                                      
                                                                                                                                                           
   CloseHandle (hModuleSnap);                                                                                                              
   return false;                                                                                                                                      
}                                                                                                                                                           
                                                                                                                                                           
                                                                                                                                                           
                                                                                                                                                           
bool CGomControl::GomClose(){                                                                                                           
   return ProcessKill(_T("GOM.exe"));//실제 죽이는 구문      

Posted by SB패밀리
플랫폼에 대한 이야기는

윈도우즈와 맥OS, 유닉스 와 같은 OS플랫폼과 유사한, 아니 확장된 개념으로 이해해도 될 듯하지만
시장이 워낙크다보니... 확장이라는 말에도 그 이상이다라고 할 만도 하다.
모바일 환경의 플랫폼... 크게는 구글 안드로이드와 애플 iOS 와의 경쟁이라고 보도 무방할듯

 
인터넷 산업에서 플랫폼 사업자들의 세력이 확장되면서 생태계 안에서는 폐쇄적 플랫폼 운영에 대한 불만도 확산되고 있다. 구글, 애플 등 막강한 플랫폼 기업의 폐쇄성을 정부나 규제기관이 나서 규제해야 한다는 이른바 `플랫폼 중립성(Platform Neutrality)'에 대한 논의가 고개를 들고 있는 것이다.

플랫폼 중립성이란 네트워크상에서 트래픽에 대한 차별 금지를 의미하는 망중립성에서 착안된 개념으로 하드웨어나 소프트웨어를 플랫폼이 차별하지 말아야 한다는 논리다.
 
2012년3월1일
출처: http://www.dt.co.kr/contents.html?article_no=2012030202014031759003 
Posted by SB패밀리
유용한 Windows 7 바로 가기 키

1. Win+D - 모든 창을 최소화하고 바탕 화면을 표시
2. Win+E - 탐색기를 시작하고 컴퓨터로 포커스를 이동
3. Win+F - 검색 창을 시작
4. Win+G - 가젯 사이를 순환
5. Win+h - 현재 창을 전체 화면으로 이동
6. Win+i - 현재 전체 화면을 정상 크기로 복원하거나 현재 창이 전체 화면이 아닌 경우 최소화
7. Win+L - 바탕 화면을 잠금
8. Win+M - 현재 창을 최소화
9. Win+R - 실행 창을 오픈
10. Win+U - 사용 편의 센터를 오픈
Posted by SB패밀리


시작프로그램에 등록된 프로그램이 실행되지 않는 문제의 해결

1. 증상의 개요
● 사용자가 시작프로그램에 등록하여 윈도우 기동과 동시에 실행을 기대한 프로그램의 바로 가기가 모두가 다 실행되지 않는 증상입니다.

 

2. 해결책

 

현재 이 값일 수도 있습니다.

%USERPROFILE%\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup

● 레지스트리 편집기를 실행하여 아래 위치까지 찾아갑니다.

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders

● shell folder의 path를 아래와 같이 각각 초기값으로 변경합니다.

Startup을 더블클릭하여 데이터를 아래와 같이 변경합니다.

%USERPROFILE%\Start Menu\Programs\Startup

● 주의점 : 값의 종류가 REG_EXPAND_SZ이며 REG_SZ가 아닌 것에 주의합니다

 

Posted by SB패밀리


[IT/OS] 바탕화면을 D드라이브로 변경하기

우연히 알게되서 이렇게 올려봐요 ^^

보통 우리가 쓰는 컴퓨터에  내문서안에 저장을 하면 자동으로 D드라이브로 저장되게끔 내문서 위치를 바꿀 수 있습니다.
바탕화면과  즐겨찾기도 요즘 많은 데이터와 중요 사진 및 파일들을 저장하면서 쓰게 됩니다.
만약 포맷을 할 경우 바탕화면에 많은 중요 데이터를 저장하였다면  그때 그때마다 백업 시간이 많이 걸리게 됩니다.

그래서 바탕화면과 즐겨찾기도 내문서 같이 위치를 D드라이브나 다른 드라이브로 저장할수있게 위치를 바꿀수있습니다.
아래 순서대로 작업하면 변경이 됩니다.

1 시작 -  실행을 클릭
2 REGEDIT 를 실행
3 레지스트리에서 HKEY_CURRENT_USER \ Software \ Microsoft \ Windows \ CurrentVersion \ Explorer 로 이동
4 User Shell Folders 클릭해서 Desktop 값을 클릭하셔서 원하는 위치를 변경
5 재부팅한 후 바탕화면에 저장하면 원하는 위치에 저장이 됩니다

즐겨찾기도 가능합니다. Favorites 값을 수정하면 가능합니다.

Posted by SB패밀리

윈도우즈에서 실행중인 프로세스를 강제 종료시키자.
내가 사용하는 방법도 있지만 아래 소스가 잘 정리되어 있어서 그대로 스크랩했다.

출처 : http://koronaii.tistory.com/241

BOOL CGomControl::ProcessKill(CString strProcessName)                                                                      
{                                                                                                                                                          
   HANDLE hProcessSnap = NULL;                                                                                                         
   BOOL bRet = FALSE;                                                                                                                         
   PROCESSENTRY32 pe32 = {0};                                                                                                         
                                                                                                                                                          
   hProcessSnap = CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, 0);                                             
   if (hProcessSnap == (HANDLE)-1)                                                                                                      
       return false;                                                                                                                                 
   pe32.dwSize = sizeof(PROCESSENTRY32);                                                                                         
                                                                                                                                                          
   //프로세스가 메모리상에 있으면 첫번째 프로세스를 얻는다                                                                       
   if (Process32First(hProcessSnap, &pe32))                                                                                           
   {                                                                                                                                                     
       BOOL bCurrent = FALSE;                                                                                                              
       MODULEENTRY32 me32 = {0};                                                                                                      
                                                                                                                                                          
       do {                                                                                                                                            
           bCurrent = GetProcessModule(pe32.th32ProcessID,strProcessName);                                           
           if(bCurrent) {                                                                                                                           
               HANDLE hProcess = OpenProcess(PROCESS_ALL_ACCESS, FALSE, pe32.th32ProcessID);          
               if(hProcess) {                                                                                                                       
                   if(TerminateProcess(hProcess, 0)) {                                                                                   
                       unsigned long nCode; //프로세스 종료 상태                                                                      
                       GetExitCodeProcess(hProcess, &nCode);                                                                        
                   }                                                                                                                                     
                   CloseHandle(hProcess);                                                                                                    
               }                                                                                                                                         
           }                                                                                                                                             
       }                                                                                                                                                 
       //다음 프로세스의 정보를 구하여 있으면 루프를 돈다.                                                                          
       while (Process32Next(hProcessSnap, &pe32));                                                                                
   }                                                                                                                                                     
                                                                                                                                                          
   CloseHandle (hProcessSnap);                                                                                                            
   return true;                                                                                                                                      
}                                                                                                                                                           
  
                                                                                                                                                        
BOOL CGomControl::GetProcessModule(DWORD dwPID, CString sProcessName)                                       
{                                                                                                                                                          
   HANDLE hModuleSnap = NULL;                                                                                                          
   MODULEENTRY32 me32 = {0};                                                                                                          
                                                                                                                                                          
   hModuleSnap = CreateToolhelp32Snapshot(TH32CS_SNAPMODULE, dwPID);                                         
   if(hModuleSnap == (HANDLE)-1)                                                                                                        
       return (FALSE);                                                                                                                            
   me32.dwSize = sizeof(MODULEENTRY32);                                                                                          
                                                                                                                                                          
   //해당 프로세스의 모듈리스트를 루프로 돌려서 프로세스이름과 동일하면                                                    
   //true를 리턴한다.                                                                                                                             
   if(Module32First(hModuleSnap, &me32)) {                                                                                          
       do {                                                                                                                                            
           if(me32.szModule == sProcessName)                                                                                         
           {                                                                                                                                             
               CloseHandle (hModuleSnap);                                                                                                 
               return true;                                                                                                                          
           }                                                                                                                                             
       }                                                                                                                                                 
                                                                                                                                                          
       while(Module32Next(hModuleSnap, &me32));                                                                                  
   }                                                                                                                                                     
                                                                                                                                                          
   CloseHandle (hModuleSnap);                                                                                                             
   return false;                                                                                                                                     
}                                                                                                                                                          
                                                                                                                                                          
                                                                                                                                                          
                                                                                                                                                          
bool CGomControl::GomClose(){                                                                                                          
   return ProcessKill(_T("GOM.exe"));//실제 죽이는 구문                                                                           
                                                                                                                                                          

Posted by SB패밀리