RobotStudio event

File path to home dir

Options

I have made a function to save receipe data to XML file. It works on VC but not at the real FP. Can sombody help witk the syntax path to save file in home. I,v tried with the on i use in rapid code but it wont work

The path "HOME:/Receptdata.mod" in rapid code

Best regards Klaus

Best Regards

Klaus Soenderhegn
www.cadalysator.dk

Comments

  • RussD
    Options

    The default value of RemoteDirectory should be the home directory of your current system.

    I assume that you are using .Net functionality to create your files, but these components don't know anything about the robot controller, so you need to create and save your file on the FlexPendant (LocalDirectory) then use PutFile to copy/save it to the controller (RemoteDirectory). Check to see what the value of LocalDirectory is, I believe it is /temp, which is a directory on the FlexPendant's file system, which .Net will be able to use.

    If you search "file" or something similar in this forum, I think you will find other postings that talk about this issue too.

    Russell Drown
  • Klaus
    Options

    Hei Russ.

    thanks for your help. I can see how to put and get files but how do i creat til file, read and write to it. normel i use open for output or input and then close. Read and write lines

    Klaus

    Best Regards

    Klaus Soenderhegn
    www.cadalysator.dk
  • Hello Klaus,

    In RAB 5.10, which will soon be released, the static property ABB.Robotics.Controllers.SystemInfoDomain. SystemInfo.SystemPath  returns the path in the controller file system to the system directory of the active system, and you just need to add "/HOME" to the returned string to get the complete path to the HOME directory.

    For .NET related issues, such as how to create the file, you need to use Microsoft's .NET documentation, either from Windows Start button or at MSDN  (Microsoft Developer Network) at www.msdn.com.  Check that the method you want to use is supported by the software platform that the FlexPendant uses:  Windows CE and .NET Compact Framework (2.0 ).

     

    Best regards,

    Ingela Brorsson
    Software Engineer
    ABB Robotics, Sweden