GravityForm: Populate Dropdown with custom post type [closed]

The id to your form should be 51 for your code to work, hope the code is placed in functions.php

For gform_pre_render_51, 51 is the id of the form whose select field you are trying to modify