Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

crosstab rowscopy

95 views
Skip to first unread message

Dark

unread,
Mar 23, 2005, 1:42:53 PM3/23/05
to
PB 9.0
How copy data from one to another crosstab.
Second dw is for printing in somposite report (Retrieve 10 - 20 sec.).

Dark

dawntbrowneyes

unread,
Mar 24, 2005, 9:53:30 AM3/24/05
to

Rowscopy, ShareData... Are all copying, manipulating
the buffers. You will need to copy the headers, text
fields...

I have a similar application where I pass the datawindow
to a generic print window. In the print window I put the
passed datawindow in print preview mode and they can
resize, modify, shrink, zoom ... the printpreview window
without changing the original datawindow. I can't use
Sharedata, rowscopy because I need to copy the headers
nested reports... If the headers have been changed in
script
or there are nested reports, sharedata won't work. So what
I use
is the functions: GetFullState and SetFullState.
GetFullState
will get the entire datawindow resultset, headers.... and
convert it to a blob. I then convert this blob back to a
datawindow in the printpreview window using setfullstate.

For a composite report you will need the getchild fx
to get the reference to the nested report.

for example:
dw_1.getfullstate(lblob)
dw_composite.getchild('nestedreport',dwchild)
dwchild.SetFullstate(lblob)

I am pretty sure something like that should work.
I am not at my computer ( I am on a Mac ) ;-)
so I can't make sure it will work also my syntax
may be a little rusty. Sorry

Please post your solution. I am sure others will
be interested. This is a very useful application. ie
reusing a datawindow in it's entirety without retrieving
it again.

If you can't get it to work I can look at it this weekend.
I don't want to leave this unanswered until the weekend
when I am pretty sure this will work.

HTH

Dark

unread,
Mar 25, 2005, 3:41:02 AM3/25/05
to

> for example:
> dw_1.getfullstate(lblob)
> dw_composite.getchild('nestedreport',dwchild)
> dwchild.SetFullstate(lblob)
>
> HTH

SetFullState not work for DataWindowChild object.
Dark


dawntbrowneyes

unread,
Mar 28, 2005, 1:57:57 PM3/28/05
to

The only way I can think of is to create
a temporary table in Powerbuilder then
call the stored procedure that does the
processing ... (20 minutes)...
(use the retrieve or embedded sql)
and populate the temporary in the sp.
Then you can use the temporary table
to populate the single datawindow and
the nested datawindow in the composite
report. I would populate the nested dw
after populating the single datawindow and
then drop the temp table.

If the temp table is populated in PB then
it will be available on the server and
can be populated and it will still be available
on the client and can be retrieved multiple
times.

0 new messages