private void LoadContentView() { ContentView contentView = (ContentView)GetViewByName("contentView"); for (int i = 0; i < Database.TableList.Count; i++) { if (isAdmin || (bool)Database.TableList[i]["needNotAdmin"]) { contentView.AddTable((string)Database.TableList[i]["attribute"]); } } contentView.SelectTable += ContentView_SelectTable; contentView.ShowDialog(); }