How it works...
When the user clicks New (or the form is opened with a menu item that has Open Mode set to Yes), the form triggers a task that calls the current data source's Create method. In our case, we must let the data source do this; however, at this point, we will open the create dialog using the create method we wrote on the form handler.
The create method is a standard way to call any form from code. Never use the form name as a string literal without using an intrinsic function; in this case, formStr.
This calls the create dialog that is set up so the normal form events no longer fire. We will initialize the form from the form handler class in order to pass back the new record.
Once control returns back to our details form, we will ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access