예제 #1
0
        public static bool hasCopy(string upc)
        {
            bool hasCopy;

            adapter = getNewAdapter();
            DataTable table = adapter.GetCopy(upc);

            adapter.Dispose();

            hasCopy = table.Select().Length > 0;

            return(hasCopy);
        }
예제 #2
0
        public static bool isAvailable(string upc)
        {
            bool isAvailable = false;

            adapter = getNewAdapter();
            DataTable table = adapter.GetCopy(upc);

            adapter.Dispose();

            if (table.Select().Length > 0)
            {
                isAvailable = (bool)table.Select()[0].ItemArray[1];
            }

            return(isAvailable);
        }