- Log in to post comments
User bio
404 bio not found
Member since Mar 10, 2021
Posts:
Martin has not published any posts yet.
Replies:
What about this one:
ClassMethod Indirection() [ ProcedureBlock = 0 ]{
N (evenTotal)
set TABLES(0)="EVEN"
set TABLES(1)="ODD"
for i=1:1:100 {
set table = TABLES((i#2))
set @(table_"("_i_")")=i
// Xecute alternative, same issue
; set cmd = "set "_table_"("_i_")="_i
; x cmd
} set evenTotal=0
set i="" for { set i=$ORDER(EVEN(i)) QUIT:i=""
set evenTotal = evenTotal+EVEN(i)
}
zwrite evenTotal}- Log in to post comments
It is Windows 64 bit. But the problem is solved now.
- Log in to post comments
Certifications & Credly badges:
Martin has no Certifications & Credly badges yet.
Followers:
Martin has no followers yet.
Following:
Martin has not followed anybody yet.
This solution will work because global variable is visible on all stack levels (local variable is not).
But you'd use process private global varialble ^||pasp("unitcode") instead of ^pasp("unitCode") which is visible from all processes and you can have collisons in multi user environment.