On_Select userexit in widget-menus/button-areas or On_Event userexit in widget state of an active mask.
In query mode of mask edit state you can formulate search criteria in the fields of the mask, in order to search for data. The query itself can be initiated using userexits, like wdh_cnt_lis or wdh_upd_lis.
Example:
In DataView itself the userexit is used for the standard function query in the NoSelect menu.