RobotStudio event

Question about writing to Rapiddata

Options

Hi,

Just a small question. I'm writing an array of num data to the controller. The question is. Do I have to read every single entry first, before I can write the data, or is there some better method to do this? You can se how I do in the image below.

image

It actually works this way, I only wonder if there is a better way to do it.

/PerM

Comments

  • Hi,

    The ArrayData.FillFromString method is meant to be able to write to a RAPID array in one call - BUT

    image It has just been discovered that ArrayData.FillFromString is not correctly implemented. This bug exists in previous releases as well. As a workaround the property RapidData.StringValue can be used to read and write small arrays in one call (less than 100 num elements).<?:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />


    using (Mastership.Request(m_controller.Rapid))
    {  myRapidData.StringValue = "[1.0, 0.5, 0.6, 2.0]"; }
    Best regards,

    Ingela Brorsson
    Software Engineer
    ABB Robotics, Sweden