The following would clear all the problems we are facing.
Create a column like this.We are not using any attribute name.We are just creating an input which has html attribute username which is unique for each field.
would be helpful in collecting data if we are treating the grid as form.
Now register below the grid the following script.
It ensures two things.
1.Auto complete is available even after a AJAX calls.
2.It also generates the source.
I am getting all the usernames from table user.
section-grid is the id of my CGridView.
Be careful with single and double quotes.