First set up an empty Choice List for each desired field. Inside the project method called DAX_Devhook_InstallChoiceList, put a call to DAX_Dev_SetChoiceList() for each field. Here are the specific calls in this example:
At this point you would see Choice Lists for the five fields, but they would contain no data.
Your Choice List could just receive data as is from a pre-existing 4D list in the Toolbox. Or you can override that data, or create the data totally from scratch, inside the project method DAX_DevHook_ListContents. Then just associate the data to the list you created in DAX_Devhook_InstallChoiceList. In this example data is all created on the fly.
Let's look at sample code for just one of the five Choice Lists. First declare variables for the incoming parameters.
Test for each list you are trying to intercept or create. Only "task_repeat" is examined in this example. We declare a fresh array rather than dereferencing the passed in pointer, since we are simply going to create some values for it here.
Now put whatever values you want in the array. Here it is hard-coded, but the values could be arrived at programmatically.
And we are done!
The DAX_Devhook_InstallChoiceList method provides a very convenient way to populate data into Choice Lists.