Hey guys,
Any idea why this code would produce a blank rootelement in my table when
passing in an Alert object and a string, when if I just use a basic
RootElement and pass a string for caption it works fine?
public class AlertRootElement : RootElement {
static NSString key = new NSString ("alertRootElement");
public EbayNotifierService.Alert Alert;
public AlertRootElement (EbayNotifierService.Alert alert, string
caption) : base (caption)
{
Alert = alert;
}
public override UITableViewCell GetCell (UITableView tv)
{
var cell = tv.DequeueReusableCell (key) as AlertDataCell;
if (cell == null)
cell = new AlertDataCell (Alert, key);
else
cell.UpdateCell (Alert);
return cell;
}
public void Delete() {
Console.WriteLine(String.Format("Deleting record {0}", Alert));
EbayNotifierService.EbayNotifier ebayNotifierService =
new
EbayNotifierService.EbayNotifier();
ebayNotifierService.DeactivateAlertAndItems(Alert.AlertID);
}
}
--
View this message in context:
http://monotouch.2284126.n4.nabble.com/Custom-RootElement-showing-up-blank-tp3903751p3903751.html
Sent from the MonoTouch mailing list archive at Nabble.com.
_______________________________________________
MonoTouch mailing list
[email protected]
http://lists.ximian.com/mailman/listinfo/monotouch