HALDUU/CANU Replace the DataWindow Object dynamically in a DataWindow control

I have an existing datawindow control for which I need to present different
looks depending on the department using the control.  There is quite a bit
of logic around it so what I wanted to do do was resave with a different
name of my original datawindow object and then use either object in the
control.  Thus when 1 type of user comes in 1 dw object is displayed and
used and when another user type comes in another dw object is used.  I
believe I could probably use .ShareData, but was hoping I could simply
replace the datawindow object for a single control (have done something
similar for dddw).

TIA

Joe Dale
Wright Industries





0
Joe
11/23/1998 11:19:58 PM
📁 sybase.powerbuilder.database
📃 9855 articles.
⭐ 2 followers.

💬 2 Replies
👁️‍🗨️ 776 Views

"Joe Dale" <[email protected]> wrote:

>I have an existing datawindow control for which I need to present different
>looks depending on the department using the control.  There is quite a bit
>of logic around it so what I wanted to do do was resave with a different
>name of my original datawindow object and then use either object in the
>control.  Thus when 1 type of user comes in 1 dw object is displayed and
>used and when another user type comes in another dw object is used.  I
>believe I could probably use .ShareData, but was hoping I could simply
>replace the datawindow object for a single control (have done something
>similar for dddw).

Change the DataObject property of the control. That property contains the name
of the datawindow object.

This is discussed briefly in the Fast Track to PowerBuilder and in more detail
in the Mastering DataWindows.
---
Craig Wagner                   | E-mail:  [email protected]
CPD Professional               | Web:     http://www.metacorp.com
Certified Powersoft Instructor | Phone:   (503) 452-6343
Portland, OR USA               |

Keeper of the PowerBuilder FAQ
http://www.teleport.com/~wagnerc/powerbuilder_faq.html
0
cwagner
11/24/1998 1:20:28 AM
Thanks

dw_master.DataObject = 'd_blah_blah_blah'

Worked Great



0
Joe
11/24/1998 4:36:19 PM
Reply: