10/5/2022 10:12 AM | |
Joined: 3/23/2021 Last visit: 4/22/2024 Posts: 5 Rating: (0) |
Somehow, this doesn't appear to be working for me. I'm running WinCC Advanced V17. In my script I have a for loop that uses the variable "k" When I try to access the values in the array with this line:
the result is always "0". When I enter a number instead of the variable, I get the correct value.
I've also tried assembling the whole name of the tag before the Smarttag but both versions didn't work either.
Does anyone have an idea what the problem could be? Best wishes Malte ______________________________________________________ Edit: I've figured it out, thanks to Murof. When the values aren't displayed, they don't get updated. Now I'm just switching to a different screen and al the values that I need are behind a big white box and not visible, but on screen. Not the nicest solution, but it works. ------------------------------------------------------------------------------------------ |
Last edited by: Jen_Moderator at: 10/05/2022 11:50:28New subject after splitting Last edited by: mduckhorn at: 10/05/2022 12:07:32 |
|
10/6/2022 9:11 AM | |
Joined: 7/5/2013 Last visit: 4/26/2024 Posts: 3076 Rating: (505)
|
Hello Malte, additionally you can have a look to the following FAQ: Tips and tricks for creating scripts in WinCC (TIA Portal). There are two hints for working with arrays in scripts. Regards, Frink |
Pi is exactly three! |
|
10/10/2022 11:05 AM | |
Joined: 8/3/2009 Last visit: 4/26/2024 Posts: 12869 Rating: (1641)
|
Hello mduckhorn Its because of: "Current system behavior for dynamic access to elements of a user data type" Bye Murof |
If this Information really helps, you could use the Rate function |
|
12/13/2023 11:59 AM | |
Joined: 8/21/2014 Last visit: 4/26/2024 Posts: 949 Rating: (13) |
New question published by AutoGen_9763591 is split to a separate thread with the subject I want to access a mnemonic in a datablock. Best regards |
My Forum is the place to personalize your profile, |
|
This contribution was helpful to1 thankful Users |
Follow us on