How to Call Your Own Lookup Windows

Previous Next

Default lookup windows are called from lookup buttons based on relationships you have defined. You may want to call a user-defined lookup window class or subclass instead, but still use the lookup button and basic lookup functionality.

You can only call default or user-defined lookup windows from query columns that are defined as a foreign key in a relationship.

If you want to call a lookup dialog from an inserted text box instead of from a query column, refer to: How to Call a Lookup Dialog.

To call your own lookup window:

1.Create a new lookup window class or subclass. Base this class on the Lookup Window style sheet. Define specifications for this class now or at a later time.
2.Open the Property Inspector for the query column from which you want to call the lookup window.
3.Set the Lookup Method behavior property to

WindowCreateLookup(<lookup window class name>)

or click the Edit button and drag the lookup window class into the Object Activator. In this case the Object Activator generates a method call using the Create() method and the syntax will be:

<lookup window class name>.Window.Create()