NetTalk Central

NetTalk Web Server => Web Server - Ask For Help => Topic started by: Alberto on April 01, 2009, 03:34:35 AM

Title: Sort browse depending on parent
Post by: Alberto on April 01, 2009, 03:34:35 AM
Hi,
Any easy way to sort the browse depending on the parent?

Thanks
Alberto
Title: Re: Sort browse depending on parent
Post by: Bruce on April 01, 2009, 04:20:40 AM
Parent or Caller?

If you have "child browses" then the parent is the one calling the children.

If you have a browse on a form then the Form is the parent, and the browse is the child.

In other words, to be a parent the parent is always visible as well as the child.

In your earlier thread you talked about a browse calling a form, and thus being the parent of the form. This is inaccurate. It's not the parent, it's the caller.

Cheers
Bruce
Title: Re: Sort browse depending on parent
Post by: Alberto on April 01, 2009, 04:24:35 AM
Sory,

I have a browse on a form then the Form is the parent, and the browse is the child.

This browse is child of many forms and I need to sort it depending on the form (parent)

Thanks
Alberto
Title: Re: Sort browse depending on parent
Post by: Bruce on April 01, 2009, 04:56:06 AM
you're best then adding some hand-code to the browse, just ater the sort order is set. You can use loc:parent to know which form you are on.

If you right-click, and choose Source, go to the GenerateBrowse routine. Just before the LOOP statement you should be able to see how the sort order is set.

cheers
Bruce
Title: Re: Sort browse depending on parent
Post by: Alberto on April 01, 2009, 05:05:51 AM
OK, and continuing with my other post.

If I have some browses, which updetes with the same form, how to know in the form woch browse is the caller?

Alberto
Title: Re: Sort browse depending on parent
Post by: Bruce on April 01, 2009, 08:55:46 PM
Hi Alberto,

Set a session value in the GenerateBrowse routine of the browse, and read it in the Form where you need it.

Cheers
Bruce