8/10/2020 9:43 AM | |
Joined: 10/7/2015 Last visit: 9/8/2022 Posts: 14 Rating: (2) |
Hello, i have similar problem. When i used internal tag as type Array: @CatX_SubCount Array [0..10] of Int with Start value 0 and i tried to use inside script HMIRuntime.Tags.SysFct.SetTagValue("@CatX_SubCount[0]", 0); or Tags("@CatX_SubCount[0]").Write(0); or let SubCatCount = Tags(`@CatX_SubCount[${iCat}]`); HMIRuntime.Trace("SubCatCount: " + SubCatCount.Read()); then i have this error msg: CHmiRuntime IID_IName could not find Tag HMI_RT_2::@CatX_SubCount[0] If i tried to read value of this tag HMIRuntime.Trace(Tags("@CatX_SubCount[0]").Read()); then msg is: Read of Tag '@CatX_SubCount[1]' failed because 'The given tag does not exist.'ScriptContext:HMI_RT_2::02_Menu Function:_2_Menu_OnLoaded If i use local variable inside script, then it works: let Test = [0,1,2,3,4,5]; HMIRuntime.Trace("Test 1: " + Test[1]); Is there any limitation for useable tags inside scripts? Many thanks... ------------------------------------------------------------------------------------------ |
Last edited by: Jen_Moderator at: 08/10/2020 10:19:45New subject after splitting |
|
Follow us on