RobotStudio event

Load / UnLoad

Hello All,

Is it possible to load and unload a .Log or a .txt?


Comments

  • soup
    soup ✭✭✭
    "Load" and "Unload" are for modules, but "ReadStr" can read and "Write" can write text file data.
  • I am able to read and write to the .log or .txt, but I want to be able to save it to a connected network automatically once a week. 

    I am having to do it manually.

    thank you.

  • Look at the help on the CopyFile instruction, it will take a file from one directory and copy it to another. You probably want to time and date stamp it or something.

    For regular triggering maybe you could occasionally check the time and date (CTime and CDate functions) and compare that to the last time you moved the file. 

    Below is some code which might help.

    sTime:=StrPart(CTime(),1,2)+StrPart(CTime(),4,2);
    sLogFileName:="LogFile_Saved_"+CDate()+"_"+sTime+".txt";
    !
    CopyFile "HOME/LogFile.txt","E:/"+sLogFileName;
  • soup
    soup ✭✭✭
    1. Check that you have the FTP option on your controller
    2. Add your FTP server to the controller's configuration under the Communication tab
    3. Trigger write/copy/read based on day of the week