tab_1.page1.tab_2.page1.tab_3.page1.dw_1
Accessing dw_1 in code would make my code too long. I would
like that in code, I can maybe declare a datawindow variable
(ldw_ref) and assign dw_1 into that variable as reference so
that in code, I may just write it shorter. Instead of
writing, tab_1.page1... until I reached dw_1. repeating that
for all columns of dw_1 is so tedious to write.
All I know is that I can pass it to a function as reference.
But I am not coding in a function. Is there any other way to
achieve the above outside a function?
TIA
Neil
Yep, just like that.
datawindow ldw_1
ldw_1 = tab_1.page1.tab_2.page1.tab_3.page1.dw_1
ldw_1.retrieve()
...
1) declare instance array of datawindow type:
datawindow dws[]
2) for each of the datawindow controls within tabpages declare instance
constant to be used as index within the array:
constant integer CI_DW_MAIN = 1
constant integer CI_DW_EDU = 2
constant integer CI_DW_HIST = 3
etc...
3) on window opening prepare the array, just like Jeremy wrote:
dws[CI_DW_MAIN] = tab_1.page1.dw_main
dws[CI_DW_EDU] = tab_1.page1.tab_2.page1.dw_education
dws[CI_DW_HIST] = tab_1.page1.tab_2.page1.tab_3.page1.dw_1
etc.
4) after that, simply use dws[<CI_dw_constant>] to reference the desired
control
And I hope that the example you wrote
"tab_1.page1.tab_2.page1.tab_3.page1.dw_1" is not a real thing - I would
prefer to put meaningful suffixes of the controls instead of the default
numeric ones :-)
Regards,
Ivaylo
"Jeremy Lakeman" <jeremy....@gmail.com> wrote in message
news:530b500c-d10b-44de...@b25g2000prb.googlegroups.com...