コード例 #1
0
        private static List<View> FindView(List<View> lstView, View View)
        {
            List<View> lbt = new List<View>();

            foreach (View bt in lstView)
            {
                if (bt.Name.ToUpper().Trim() == View.Name.ToUpper().Trim())
                {
                    lbt.Add(bt);
                }
            }

            return lbt;
        }
コード例 #2
0
 public bool RemoveView(View View)
 {
     return this.views.Remove(View);
 }
コード例 #3
0
        public void GetAllView()
        {
            if (connectionString == null || connectionString.Length == 0) throw new ArgumentNullException("connectionString");

            this.views.Clear();

            foreach (string viewName in GetDatabaseObjectList(this.connectionString, DatabaseObjectType.View))
            {
                View view = new View(viewName.Trim());
                FillSchemaTable(view as BaseTable, GetSchemaTable(this.connectionString, viewName.Trim()));
                this.views.Add(view);
            }
        }
コード例 #4
0
        public bool AddView(string viewName)
        {
            viewName = viewName.Trim();

            foreach (View view in this.views)
            {
                if (view.Name.ToUpper().Trim() == viewName.ToUpper().Trim())
                {
                    return false;
                }
            }

            View newView = new View(viewName.Trim());
            FillSchemaTable(newView as BaseTable, GetSchemaTable(connectionString, viewName.Trim()));
            this.views.Add(newView);

            return true;
        }
コード例 #5
0
        public bool AddView(View View)
        {
            foreach (View view in this.views)
            {
                if (view.Name.ToUpper().Trim() == View.Name.ToUpper().Trim())
                {
                    return false;
                }
            }

            this.views.Add(View);
            return true;
        }
コード例 #6
0
 public void ShowViewInfo(Model.View view)
 {
     AddObjectToListView(lvObjectInformation, view);
 }