Thanks, It work for me. Regards Imran ali
On May 25, 10:11 pm, TreKing <[email protected]> wrote: > On Wed, May 25, 2011 at 4:29 AM, imran ali <[email protected]> wrote: > > i am getting this exception > > "The specified child already has a parent. You must call removeView() > > on the child's parent first." > > > what is will be solution?? > > When you specify a ViewGroup as the second parameter of inflate, that's the > group the inflated view gets added to. So you're adding your inflated view > to "linearlayout". > > You then immediately add the child you inflated to second ViewGroup, "IL". > > So, as the error clearly indicates, you're adding a View to a new ViewGroup > when it already has a parent set. > > Do one or the other, but not both. > > In this case you probably just need to remove the call to IL.addView(). > > ------------------------------------------------------------------------------------------------- > TreKing <http://sites.google.com/site/rezmobileapps/treking> - Chicago > transit tracking app for Android-powered devices -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

