NOTE: Unfortunately, i am unable to post links as i have just joined the forum.
I am new to Xamarin forms and i am stuck on a problem. I want an autocomplete to suggest items to a user entering text into a field. The data is to be retrieved from a REST Api showing the user the name of the product whilst the code behind is able to keep track of the product Id.
In my search, this does not seem to be straight forward.
I have implemented the code from xLabs autocomplete as per their sample.
Running on iOS i recieve this error.....
Objective-C exception thrown. Name: NSInternalInconsistencyException Reason: Invalid update: invalid number of rows in section 0. The number of rows contained in an existing section after the update (1) must be equal to the number of rows contained in that section before the update (1), plus or minus the number of rows inserted or deleted from that section (1 inserted, 0 deleted) and plus or minus the number of rows moved into or out of that section (0 moved in, 0 moved out).
Native stack trace:
0 CoreFoundation 0x000000010475a12b __exceptionPreprocess + 171
1 libobjc.A.dylib 0x0000000112028f41 objc_exception_throw + 48
2 CoreFoundation 0x000000010475f2f2 +[NSException raise:format:arguments:] + 98
3 Foundation 0x0000000105389d69 -[NSAssertionHandler handleFailureInMethod:object:file:lineNumber:description:] + 193
4 UIKit 0x000000010949c209 -[UITableView _endCellAnimationsWithContext:] + 19416
5 UIKit 0x00000001094b7075 -[UITableView endUpdates] + 75
6 BlueHeronJets.iOS 0x000000010407d9f9 xamarin_dyn_objc_msgSend + 217
The xlabs page does not seem to have any documentation anymore on their github wiki.
There is a similar bug reportedon another site, which i can't link to, where the solution is to downgrade to Xamarin.Forms 184.108.40.2060 but this did not solve my problem.
1) Does anyone know what this error is and why it occurs using this example component?
2) Are there alternatives or design patterns for creating this effect?
There must be a simple approach to this. It's pretty standard.
How do you have an entry box, which autosuggests a answer and tracks the id of that answer.