I'm trying to create the following logic:
Step one : Check if the values have been stored more then x time, if so delete them.
Step two : Check if current value has been used before
Step Three : If used return False (and write value to Datatable), else return true (dont' write the value to the arraylist).
I thought this would be best if I create an DataTable. But how do i go about this?
Loading
LexPosted Jul 20, 2010, 12:28 PM
Sam HobbsPosted Jul 20, 2010, 12:19 PM
Mamta MPosted Jul 19, 2010, 7:22 AM
LexPosted Jul 19, 2010, 6:27 AM
Therefore I thought of creating a datatable, and when a barcode get scanned, I check the table if there are any barcodes in there that have been scanned outsite the x time, if so delete them, then I only have the barcodes left that have been scanned withing x time.
I then check to see if the current scanned barcode is in the list, if not then add it to the list, and allow the barcode through, else don't allow the barcode and return an error.
I have never worked with in memory tables like this and I was hopping that someone can point me in the right direction.
Mamta MPosted Jul 19, 2010, 6:20 AM
Step one : Check if the values have been stored more then x time, if so delete them.
Delete FROM WHERE? This is not clear
Step two : Check if current value has been used before
You can use Contains method to check this.
Step Three : If used return False (and write value to Datatable), else return true (dont' write the value to the arraylist).
This again was not clear...elaborate little more.
I thought this would be best if I create an DataTable. But how do i go about this?
What exactly are you trying to populate?