I have created custom form in Moodle and inserted the data into moodle database. Also i used most of the field in form as autocomplete like below eg
$mform->addElement('autocomplete', 'SBName', get_string('searcharea', 'search'), $sbnames, $options);
Then, I need to update this form . I got record from db as a array, Then i need to add db values in my update form to proceed further.
Here I could not populate the values in edit form for the field of autocomplete $mform->addElement('autocomplete.
Kindly help on this to apply the values in edit form.
Please let me know Is there any way to do this in moodle