Open New Record Form with Pre-populated Fields Using Xrm.Navigation.navigateTo
This post will explain how you can pre-populate fields with various data types (lookup, partylist, etc.) when a new table form is opened using the Xrm.Navigation.navigateTo method. There is a navigateTo (Client API reference) in the Microsoft Learn but it lacks a code example for the implementation of data object parameter to set the default values to the fields when a form is opened in the create mode. The documentation simply referred to see Set column values using parameters passed to a form which only contains an example to set column values using parameters passed to a form with Xrm.Navigation.openForm . Setting column values using parameters with Xrm.Navigation.navigateTo is different from Xrm.Navigation.openForm and it could take some trial and error to get it right without the code example or the documentation of expected parameters. With the code example below, I hope you can easily pre-populated any field using Xrm.Navigation.navigat