private void simpleButton1_Click(object sender, EventArgs e)
        {
            ColumnView view = gridControl1.FocusedView as ColumnView;

            if (view == null)
            {
                return;
            }
            IListServer listserver = view.DataSource as IListServer;
            int         index      = listserver.GetRowIndexByKey(Convert.ToInt32(textEdit1.Text));
            int         handle     = view.GetRowHandle(index);

            if (handle >= 0)
            {
                view.FocusedRowHandle = handle;
            }
        }
 public NHServerModeSourceAdderRemover(Object serverModeSource, NHObjectSpace objectSpace, Type objectType)
 {
     this.serverModeSource = serverModeSource;
     this.objectSpace = objectSpace;
     this.objectType = objectType;
     listServer = serverModeSource as IListServer;
     listServerHints = serverModeSource as IListServerHints;
     bindingList = serverModeSource as IBindingList;
     typedList = serverModeSource as ITypedList;
     dxCloneable = serverModeSource as IDXCloneable;
     addedObjects = new List<Object>();
     addedObjectsDictionary = new Dictionary<Object, Byte>();
     removedObjectsDictionary = new Dictionary<Object, Byte>();
     bindingList.ListChanged += new ListChangedEventHandler(bindingList_ListChanged);
     ITypeInfo typeInfo = objectSpace.TypesInfo.FindTypeInfo(objectType);
     propertyDescriptorCollection = new XafPropertyDescriptorCollection(typeInfo);
     foreach (IMemberInfo memberInfo in NHObjectSpace.GetDefaultDisplayableMembers(typeInfo))
     {
         propertyDescriptorCollection.CreatePropertyDescriptor(memberInfo, memberInfo.Name);
     }
 }