Using Custom Cells in CBLUITableDelegate (xamarin)

I am trying to use a custom cell with couchbase CBLUITableDelegate.

I have a table with a table cell control on it which is bound to my own cell class.

I am overriding CellForRowAtIndexPath, and then need to call DequeueReusableCell with my cell identified. When I try and do this, it fails stating it cannot find my cell. (The cell reuse identifier is correctly set). If I use dequeueReusableCell with “CBLUITableDelegate” as the cell name, it works, but does not return my custom type.

Is the the way to do it with couchbase lite, or is there a better method when you can override the cell, and use your own cell format?

Does anyone have any sample code on how to do this - I have managed this successfully when n to using CBLUITableDelegate, but have not managed to yet do this with couch base.

Thanks in advance

Are you implementing the right delegate method? The one to override is

  • (UITableViewCell )couchTableSource:(CBLUITableSource)source
    cellForRowAtIndexPath:(NSIndexPath *)indexPath;

not the similar delegate method defined by UITableViewDataSource.

Yes that’s the method I am overriding.

I’m not sure what’s going on, but the source code to CBLUITableSource is pretty straightforward — it’s more of a utility class than a fundamental component of the framework — and the code that calls that delegate method is very simple.

This might be a bug in your code, but if you find it’s a bug in CBLUITableSource, please file an issue on the Github tracker (couchbase/couchbase-lite-ios).