- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
How to collect all data tables in a new window
I have a script that extracts data from a database and returns a randum number of tables. I'd like to have all tables gathered in one window where a user can scroll down to see tables instead of having the tables behind each other. I have tried an approach where i make the calls to the database and afterwards make a new window and loop through all tabels and append them to the window (see below) but that does not work. Maybe the approach is all wrong and I have to start by creating the window and then add the tables when they are returned for the database or...?
thanks in advance :-)
Hans Jørgen
nw
= New Window( "EDC lag time reports for "|| Ttrial || "", show menu(0), show toolbars(0))
;
for
( i = 1, i<= N Table(), i
++,
nw
<< Append( Data Table(i) )
;
)
;
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: How to collect all data tables in a new window
Append requires a "display box" and does not recognize a Data Table as such. Try the dt << New Data Box() command to capture a table within a display box. Or if the goal is merely to browse the tables, a plain journal could work.
Examples:
nw1 = New Window("vertical tables");
nw2 = New Window("horizontal tables", hlb = H List Box());
For(i = 1, i <= N Table(), i++,
nw1 << Append(Data Table(i) << new data box); //Active tables on top of eachother
hlb << Append(Data Table(i) << new data box); //Active tables side by side
Data Table(i) << journal; // Journal; tables inactive, for browsing data only
);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: How to collect all data tables in a new window
Append requires a "display box" and does not recognize a Data Table as such. Try the dt << New Data Box() command to capture a table within a display box. Or if the goal is merely to browse the tables, a plain journal could work.
Examples:
nw1 = New Window("vertical tables");
nw2 = New Window("horizontal tables", hlb = H List Box());
For(i = 1, i <= N Table(), i++,
nw1 << Append(Data Table(i) << new data box); //Active tables on top of eachother
hlb << Append(Data Table(i) << new data box); //Active tables side by side
Data Table(i) << journal; // Journal; tables inactive, for browsing data only
);
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Get Direct Link
- Report Inappropriate Content
Re: How to collect all data tables in a new window
YES - that made the difference. Thanks