On Nov 9, 2006, at 11:22 AM, <[EMAIL PROTECTED]>
<[EMAIL PROTECTED]> wrote:
> This works fine to add the broswer page, but I cannot figure out
> how to
> populate it with the appropriate points once I select a curve. Any
> Ideas?
If the points are dependent on the selected curve, you need to
establish the relationship between the buisness objects. So first you
need to add the points bizobj to the curve bizobj as a dependent
child, using code like this (substitute the actual field names):
pointsBizobj = app.biz.Pumppoints(app.dbConnection)
primaryBizobj.addChild(pointsBizobj)
pointsBizobj.LinkField = "curveFK"
# The next line is only needed if the linked field in the parent is
# not the PK.
pointsBizobj.ParentLinkField = "curveID"
This creates the points bizobj and relates it to the curves bizobj.
Now you can set the DataSource of your grid to the points bizobj. The
only thing left is to force the points to update when they select a
particular curve. To do that you need to add code to the event
handler for that selection; the particular event will depend on how
the selection is made. If it is based on a grid selection, you'd want
to bind the grid's GridCellSelected event to a method that calls:
self.Form.primaryBizobj.requeryAllChildren().
That should get the points data updated to the data related to the
selected curve.
-- Ed Leafe
-- http://leafe.com
-- http://dabodev.com
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users