if ((!(Array.IndexOf(loDesigner.RootComponent.GetType().GetInterfaces(), typeof(MyFramework.IContainerControl)) > -1) && loDesigner.RootComponent)) { IsNot; this; }I'm guessing that it's probably more like this:
if (!Array.IndexOf(((object)loDesigner.RootComponent).GetType().GetInterfaces(), typeof(MyFramework.IContainerControl)) > -1) && loDesigner.RootComponent != this) { // then do stuff }The "!" (or the VB "Not") is a bit confusing though. I'm translating that as meaning if the "Index is not > -1", which would be if the "Index < = -1". Hmmmm, which of course would be the same as the "Index == -1", since it's never going to be less than that. Maybe this would make a little more sense:
if (Array.IndexOf(((object)loDesigner.RootComponent).GetType().GetInterfaces(), typeof(MyFramework.IContainerControl)) == -1) && loDesigner.RootComponent != this) { // then do stuff }Fun! =0)
>If (Not Array.IndexOf(CType(loDesigner.RootComponent, Object).GetType().GetInterfaces(), GetType(MyFramework.IContainerControl)) > -1) AndAlso (loDesigner.RootComponent IsNot Me) Then >>