So you only have 1 class - EmailView - and you replace the root as needed? If it's a list and you are just searching, I thought the DialogViewController did this for you - you dont have to do anything except make sure your Element objects can response to being filtered....
On Wed, Jul 6, 2011 at 12:21, vbisbest <[email protected]> wrote: > Thank you for your response. I am sure its the way I am using this dialog. > I am trying to make a DialogViewController class, similar to the indexdialog > in the sample. Here is my constructor for my class. When a user clicks > search I populate this.Root with the new values. I noticed in my > ViewWillDisapear, this.Root.Count = 0. So its getting blown away somehow. > > namespace BMA > { > public partial class EmailView : DialogViewController > { > > UIAlertView activityView; > UIActivityIndicatorView activityIndicatorView; > > public EmailView (RootElement rootElement) : base > (rootElement, true) > { > this.ClearsSelectionOnViewWillAppear = false; > } > > This is the call in my search function after getting my emails. > > // Set the root, this populates the table > this.Root = new RootElement ("Email") { messageSection }; > > > > > > -- > View this message in context: > http://monotouch.2284126.n4.nabble.com/Root-elements-disapear-when-returning-from-dialog-tp3647436p3648435.html > Sent from the MonoTouch mailing list archive at Nabble.com. > _______________________________________________ > MonoTouch mailing list > [email protected] > http://lists.ximian.com/mailman/listinfo/monotouch > -- Nic Wise t. +44 7788 592 806 | @fastchicken | http://www.linkedin.com/in/nicwise b. http://www.fastchicken.co.nz/ mobileAgent (for FreeAgent): get your accounts in your pocket. http://goo.gl/IuBU Trip Wallet: Keep track of your budget on the go: http://goo.gl/ePhKa London Bike App: Find the nearest Boris Bike, and get riding! http://goo.gl/Icp2 _______________________________________________ MonoTouch mailing list [email protected] http://lists.ximian.com/mailman/listinfo/monotouch
