Set Current Folder PRoblem

Discuss RoboTask here
Post Reply
FourthPress
Posts: 2
Joined: Mon May 03, 2021 7:02 pm

Set Current Folder PRoblem

Post by FourthPress »

Having a problem with Set Current Folder. I am trying to move or copy selected files from one folder to another and the Set Current Folder doesnt't change to the specified folder and the macro simply creates a copy in the original folder. In the prior version of Robotask this macro worked fine. Using Windows 10 with Robotask current version
Oleg
Site Admin
Posts: 3000
Joined: Thu Jan 01, 1970 1:00 am
Contact:

Re: Set Current Folder PRoblem

Post by Oleg »

Could you send the problem task?
Or some simple example with same problem.
Oleg Yershov
FourthPress
Posts: 2
Joined: Mon May 03, 2021 7:02 pm

Re: Set Current Folder PRoblem

Post by FourthPress »

[Root]
item0000=STRINGLIST
item0001=STRINGLIST
item0002=STRINGLIST

[\item0000]
s1=[General]
s2=ActionId=A_CLIPBOARD_COPY
s3=Name=Copy
s4=Enabled=-1
s5=[Params]
s6=mode=1

[\item0001]
s1=[General]
s2=ActionId=A_FOLDER_CHANGE
s3=Name=Set Current Folder (C:\Users\FSP\Desktop\3100 Print Color\3100 Color Letter Print\Print To Letter 20# Color)
s4=Enabled=-1
s5=[Params]
s6=folder="C:\Users\FSP\Desktop\3100 Print Color\3100 Color Letter Print\Print To Letter 20# Color"

[\item0002]
s1=[General]
s2=ActionId=A_CLIPBOARD_PASTE
s3=Name=Paste
s4=Enabled=-1
s5=[Params]
s6=mode=1
Oleg
Site Admin
Posts: 3000
Joined: Thu Jan 01, 1970 1:00 am
Contact:

Re: Set Current Folder PRoblem

Post by Oleg »

Set current folder action changes the folder for RoboTask process only. Not for Windows Explorer or for system or other Windows Application.
The problem is that every Windows application can have its own current folder.
So this step has no sense in context of your task.
Look at the corrected below
Save the text of the task to a file and use menu Task->Import to import the task into RoboTask.
Do not forget to enable the task after importing.

Now you can select necessary files in Windows Explorer and press CTRL+SHIFT+ALT+C to run the task.

Code: Select all

;*****************************
;* RoboTask Task file
;* Do not edit in text editor!
;*****************************
 
[Root]
ActionAfterRun=INTEGER|0
Actions=FOLDER
Automat=INTEGER|0
CatID=INTEGER|1163085779
Comment=STRINGLIST
ContinueOnError=INTEGER|0
DisableOnError=INTEGER|0
DoNotStopWhenShutdown=INTEGER|0
Events=FOLDER
ExternalName=STRING|"Task1179"
Hide=INTEGER|0
ID=INTEGER|352642803
LogOnAsUser=INTEGER|1
Name=STRING|"Copy...(corrected 2)"
OnErrorTaskID=INTEGER|-1
Priority=INTEGER|3
RunOnClose=INTEGER|0
RunOnStartup=INTEGER|0
ToLog=INTEGER|3
UnicodeFormat=INTEGER|1
WriteGeneralLog=INTEGER|0

[Actions]
Action1=FOLDER
Action2=FOLDER
Action3=FOLDER

[Actions\Action1]
ActionID=STRING|"A_CLIPBOARD_COPY"
Enabled=INTEGER|-1
Name=STRING|"Copy"
Params=FOLDER

[Actions\Action1\Params]
mode=STRING|"1"

[Actions\Action2]
ActionID=STRING|"A_GENERAL_PAUSE"
Enabled=INTEGER|-1
Name=STRING|"Delay 2 sec"
Params=FOLDER

[Actions\Action2\Params]
delay=STRING|"2"
dimension=STRING|"1"

[Actions\Action3]
ActionID=STRING|"A_FILE_COPY"
Enabled=INTEGER|-1
Name=STRING|"Copy/Move File"
Params=FOLDER

[Actions\Action3\Params]
destdir=STRING|"C:\IMPRESSIA #10"
f_count=STRING|"1"
file0=STRING|"{ClipBoardContent}"
hidden=STRING|"1"
ifexists=STRING|"1"
move=STRING|"0"
rename=STRING|"0"
renamemask=STRING|"*.*.new"
subdir=STRING|"0"
system=STRING|"1"

[Events]
Event1=FOLDER

[Events\Event1]
Enabled=INTEGER|-1
EventID=STRING|"E_GENERAL_HOTKEY"
Name=STRING|"Shift+Ctrl+Alt+C"
Params=FOLDER
UniqueID=INTEGER|1909073996

[Events\Event1\Params]
hotkey=STRING|"57411"
Oleg Yershov
Post Reply