Author Topic: Reading Array  (Read 2467 times)

andreaboschetti71

  • Jr. Member
  • **
  • Posts: 61
    • View Profile
Reading Array
« on: December 16, 2013, 12:08:48 PM »
Is it possible to read a part of array starting from a position different from zero? I know that with command
Read("ArrayToRead",100) I can read ArrayToRead from index 0 to index 99 but if I want to read from index 20 to index 80 how can I do it?
thank you

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5322
    • View Profile
    • AdvancedHMI
Re: Reading Array
« Reply #1 on: December 16, 2013, 08:46:37 PM »
This should work:

Read("ArrayToRead[20]",80)

There is a reported issue with doing this with Bit Arrays with the CLX driver.

andreaboschetti71

  • Jr. Member
  • **
  • Posts: 61
    • View Profile
Re: Reading Array
« Reply #2 on: December 17, 2013, 03:11:02 AM »
And for DFComm driver? is it the same?

Archie

  • Administrator
  • Hero Member
  • *****
  • Posts: 5322
    • View Profile
    • AdvancedHMI
Re: Reading Array
« Reply #3 on: December 17, 2013, 07:18:53 AM »
It should work the same:

Read("N7:20",80)

andreaboschetti71

  • Jr. Member
  • **
  • Posts: 61
    • View Profile
Re: Reading Array
« Reply #4 on: January 14, 2014, 04:00:31 AM »
I tryed command Read("F60:0",184) with DFCOMM driver but only first 8 returned (ver 3.60)