Window.ShowModalWithin
From Xojo Documentation
Method
Displays the window within the parentWindow in a modal state.
Notes
ShowModalWithin is designed to display Sheet windows within a specific parent (macOS only). If it is used to display a Document window, it displays it as a non-modal dialog.