오토핫키 커뮤니티

조회 수 461 추천 0 댓글 3

 

안녕하세요

 

현재 bat파일로 백업 배치파일을 만들다 누락되는 파일이 있어

 

오토핫키로 백업파일을 만들어 보려고합니다

 

아래와 같이 filecopydir 폴더 전체 복사 명령어를 사용하였습니다

 

문제는 반응이 없습니다...

 

FileCopyDir, %userprofile%\Documents, d:\backup,1

 

실행창에서 %userprofile%\Documents 치면 내문서가 잘 열리는데요

 

filecopydir을 사용하면 복사진행이 안됩니다

 

FileCopyDir, C:\My Folder, C:\Copy of My Folder

예제글을 보았으나 내문서 지정이 안되어 위처럼 수정을 하였습니다

추가 수정으로는

FileCopyDir, C:\MyDocuments, d:\backup,1

FileCopyDir, C:\Documents, d:\backup,1

FileCopyDir, C:\%userprofile%\MyDocuments, d:\backup\,1

FileCopyDir, C:\%userprofile%\Documents, d:\backup\,1

FileCopyDir, C:\%a_workingdir%\MyDocuments, d:\backup,1

FileCopyDir, C:\%a_workingdir%\Documents, d:\backup,1

FileCopyDir, %a_workingdir%\MyDocuments, d:\backup,1

FileCopyDir, %a_workingdir%\Documents, d:\backup,1

등을 해보았지만 폴더 복사가 안되었습니다

 

아시는분 답변 부탁드립니다 ㅜ_ㅜ

 

 

;이하 소스

 

Gui, Add, Tab, x12 y10 w390 h350 , 체크|백 업
Gui, Tab, 백 업
Gui, Add, Button, x242 y50 w153 h60 , 백 업
Gui, Add, CheckBox, x20 y50 w60 h15 v내문서, 내문서
Gui, Add, CheckBox, x80 y50 w50 h15 v사진, 사진
Gui, Add, CheckBox, x130 y50 w60 h15 v동영상, 동영상
Gui, Add, CheckBox, x20 y90 w70 h15 v다운로드, 다운로드
Gui, Add, CheckBox, x90 y90 w70 h15 v즐겨찾기, 즐겨찾기
Gui, Add, CheckBox, x160 y90 w70 h15 v바탕화면, 바탕화면
Gui, Add, CheckBox, x190 y50 w50 h15 v음악, 음악
Gui, Add, Button, x242 y110 w153 h30 , 설정저장

 

Gui, Tab, 체크
Path:=A_ScriptDir
Gui, Add, Button, x250 y319 w70 h22 gFolder, 파일찾기
Gui, Add, DropDownList, x20 y320 w100 h400 vlist1, 코드|
Gui, Add, DropDownList, x125 y320 w55 h400 vlist2, 날짜|
Gui, Add, DropDownList, x185 y320 w60 h400 vlist3, 대기분||20분
Gui, Add, Button, x325 y319 w70 h22 ,
Gui, Add, GroupBox, x15 y40 w225 h270 , [Message 로그기록]
Gui, Add, listBox, x17 y58 w218 h255 vnotice_list, Message 기록이 List됩니다
Gui, Font, S35 CDefault Bold, Verdana
Gui, Add, Button, x242 y58 w153 h80 , 시 작
Gui, Add, Button, x242 y140 w153 h80 , 종 료
Gui, Add, Button, x242 y222 w153 h80 , 리 셋
Gui, Show, x391 y105 h269 w462,  PROGRAM

 

; Generated using SmartGUI Creator 4.0
Gui, Show, x356 y136 h372 w416,


#NoEnv
#SingleInstance force ; 스크립트를 동시에 한개만 실행
#Persistent ; 핫키가 없더라도 스크립트 실행을 유지
SetBatchLines,-1  ; 라인간 딜레이를 없애서 속도 상승
coordmode, pixel, screen
CoordMode, ToolTip, Screen
SetWorkingDir %A_ScriptDir%
SetWorkingDir %A_WorkingDir%
SetTitleMatchMode, 2
WinGetPos, winX, winY, winW, winH, %TILE%
WinActivate, %ActiveID%
DebugMode := 1
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.

gui, submit, nohide 
IniRead,내문서, option.ini, 내문서, 내문서
guicontrol,,내문서,%내문서%
gui, submit, nohide 
IniRead,사진, option.ini, 사진, 사진
guicontrol,,사진,%사진%
gui, submit, nohide 
IniRead,동영상, option.ini, 동영상, 동영상
guicontrol,,동영상,%동영상%
gui, submit, nohide 
IniRead,다운로드, option.ini, 다운로드, 다운로드
guicontrol,,다운로드,%다운로드%
gui, submit, nohide 
IniRead,즐겨찾기, option.ini, 즐겨찾기, 즐겨찾기
guicontrol,,즐겨찾기,%즐겨찾기%
gui, submit, nohide 
IniRead,바탕화면, option.ini, 바탕화면, 바탕화면
guicontrol,,바탕화면,%바탕화면%
gui, submit, nohide 
IniRead,음악, option.ini, 음악, 음악
guicontrol,,음악,%음악%

 


return


Folder:
FileSelectFile,newPath,%Path%,*.xls
Path:=NewPath
GuiControl,,Path,%Path%
return

 

Button백업:
 
  Gui, Submit, Nohide

FileCreateDir, d:\backup

 formattime , nowtime,,MM-dd HH:mm:ss
  guicontrol,,notice_2, %message_2%
  listMessage =%nowtime% 백업 준비.. %message_2%|%listMessage%
  guicontrol,,notice_list, |%listMessage%


if 내문서=0
{
sleep, 100
}

if 내문서=1
{
 
     FileCopyDir, %userprofile%\Documents, d:\backup,1
    
}

 
  formattime , nowtime,,MM-dd HH:mm:ss
  guicontrol,,notice_2, %message_2%
  listMessage =%nowtime% 백업 준비.. %message_2%|%listMessage%
  guicontrol,,notice_list, |%listMessage%
  return


  • T7GG 2016.09.04 17:15

    6시간만에 해결 완료

    edit을 구이에 추가하여 변수로 지정하여 계정을 입력 및 ini에 저장하여 불러오는 식으로 해결봤습니다..

     

    이제 문제는 프로그레스바 네요ㅎㅎ

     

    c:\user\%계정%\내문서

  • 제발등업좀2 2016.09.06 21:35

    안녕하세요 올만에 뵙네요 ㅋㅋㅋ 잘지내시죠~

  • T7GG 2016.09.10 16:06
    저야 잘지내죠 ㅎㅎ 명절 잘 보내시고요~

    요즘은 게임보단 업무용으로 이용하려고 머리 굴리고 있어요 ㅋㅋ

List of Articles
분류 제목 글쓴이 최근변경 추천
질문 esc를 비활성으로 키 조합 보내려고 하는데요.. 질문드... 21 껨달 2015.02.06 0/0
질문 Everything에서 오토핫키가 안 먹어요. nana34 2021.03.13 0/0
질문 exe응용프로그램 타이틀 1 yubinzz 2017.02.25 0/0
질문 exe파일 변환하는 방법이 여러가지인가요? KAZUYA 2016.10.21 0/0
질문 filecopydir 사용법 문의 글입니다 3 T7GG 2016.09.10 0/0
질문 FileCreateShortcut 관련... 2 제발등업좀2 2016.04.03 0/0
질문 FileInstall 관련 질문 41 USW 2016.10.29 0/0
질문 fileinstall 관련 질문 2 휘토리 2018.02.01 0/0
질문 fileread 저장하면 변수 오류 해결법아시는분? 1 더러럭배 2022.12.14 0/0
질문 fileread이용하여 텍스트파일로 저장을 했는데 글씨가 ... 가족오락관 2018.01.27 0/0
질문 FileSelectFolder 혹시 구이안에서 계속 띄워놀 방법... 2 제발등업좀2 2015.07.18 0/0
질문 Fps 게임 에임고정을 만들어보았는데요 도와주세요 ㅠㅠ 갓버워치 2016.07.30 0/0
질문 Fps게임에서 에임을 움직이는 법이 있을까요? 1 라미첼 2020.03.23 0/0
질문 fps에서 에임만 막히는 원리좀 알려주세요. 마룽파루 2019.05.24 0/0
질문 FTP 실시간 파일다운로드 질문 5 _Crash 2015.04.20 1/0
질문 ftp관해서 질문이 있는데요.. 2 꾸기 2017.10.19 0/0
질문 ftp에 업로드 하는 소스 있는분 도움 요청드립니다. 5 더러럭배 2018.09.26 0/0
질문 ftp전송에대해 질문좀 드리겠습니다. 2 오켕 2016.10.21 0/0
질문 Function 질문 6 마토깽 2015.07.14 0/0
자유 Function(함수)의 이해 5 리체 2015.07.28 2/0
Board Pagination Prev 1 ... 8910111213141516 ... 209 Next
/ 209

전체 최신 인기글

전체 주간 인기글