Hello all,
I have the following situation... I have a VBA code that checks an inventory sheet for deficiencies and expirations and, when it finds them, fills out each new row on the Supply Order Form with the name of the item, how many are used or expired, and puts that number in the appropriate column. Columns H-K indicate whether the item is used, expired (or expiring), damaged, or new.
The code will loop through each row and determine whether the item is already listed (in which case it adds to the existing number in the appropriate column) and, if not, creates a new line item in the next blank row and adds the data accordingly.
What I'm needing, and not sure how to even begin, is once the row has been populated with the data to check to see if more than 1 column has data in it for that specific row. Meaning, if one line item is missing 4 and 5 are about to expire, and only 7 are require to be stocked, I need the code to bring up a pop-up to alert the user that more than required is being ordered and asks if any modifications need to be made. (It's possible that some of the items that show expired were actually used). This will help not to order more than needed.
Any suggestions on how to check the 4 cells in that given row for data in 2 or more of those cells, bring up the pop-up, and if data needs to be corrected, make the appropriate changes.
If that's not enough info, or if you need clarification, please don't hesitate to ask.
Thanks in advance for your help!!!
COLUMN B COLUMN C (COLUMNS) H I J K
[TABLE="width: 946"]
<tbody>[TR]
[TD="colspan: 2"]Description[/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD]Qty[/TD]
[TD]Qty to[/TD]
[TD="colspan: 2"]Qty[/TD]
[TD]New[/TD]
[TD="colspan: 2"][/TD]
[/TR]
[TR]
[TD="colspan: 2"]Code[/TD]
[TD="colspan: 2"]Item[/TD]
[TD="colspan: 2"][/TD]
[TD]Used[/TD]
[TD]Expire[/TD]
[TD="colspan: 2"]Damage[/TD]
[TD]Item[/TD]
[TD="colspan: 2"][/TD]
[/TR]
[TR]
[TD="colspan: 2"]Order 1[/TD]
[TD="colspan: 2"]1[/TD]
[TD="colspan: 2"][/TD]
[TD][/TD]
[TD]8[/TD]
[TD="colspan: 2"][/TD]
[TD][/TD]
[TD="colspan: 2"][/TD]
[/TR]
[TR]
[TD="colspan: 2"]Order 2[/TD]
[TD="colspan: 2"]2[/TD]
[TD="colspan: 2"][/TD]
[TD]20[/TD]
[TD][/TD]
[TD="colspan: 2"][/TD]
[TD][/TD]
[TD="colspan: 2"][/TD]
[/TR]
[TR]
[TD="colspan: 2"]Order 3[/TD]
[TD="colspan: 2"]3[/TD]
[TD="colspan: 2"][/TD]
[TD]24[/TD]
[TD][/TD]
[TD="colspan: 2"][/TD]
[TD][/TD]
[TD="colspan: 2"][/TD]
[/TR]
</tbody>[/TABLE]
I have the following situation... I have a VBA code that checks an inventory sheet for deficiencies and expirations and, when it finds them, fills out each new row on the Supply Order Form with the name of the item, how many are used or expired, and puts that number in the appropriate column. Columns H-K indicate whether the item is used, expired (or expiring), damaged, or new.
The code will loop through each row and determine whether the item is already listed (in which case it adds to the existing number in the appropriate column) and, if not, creates a new line item in the next blank row and adds the data accordingly.
What I'm needing, and not sure how to even begin, is once the row has been populated with the data to check to see if more than 1 column has data in it for that specific row. Meaning, if one line item is missing 4 and 5 are about to expire, and only 7 are require to be stocked, I need the code to bring up a pop-up to alert the user that more than required is being ordered and asks if any modifications need to be made. (It's possible that some of the items that show expired were actually used). This will help not to order more than needed.
Any suggestions on how to check the 4 cells in that given row for data in 2 or more of those cells, bring up the pop-up, and if data needs to be corrected, make the appropriate changes.
If that's not enough info, or if you need clarification, please don't hesitate to ask.
Thanks in advance for your help!!!
COLUMN B COLUMN C (COLUMNS) H I J K
[TABLE="width: 946"]
<tbody>[TR]
[TD="colspan: 2"]Description[/TD]
[TD="colspan: 2"][/TD]
[TD="colspan: 2"][/TD]
[TD]Qty[/TD]
[TD]Qty to[/TD]
[TD="colspan: 2"]Qty[/TD]
[TD]New[/TD]
[TD="colspan: 2"][/TD]
[/TR]
[TR]
[TD="colspan: 2"]Code[/TD]
[TD="colspan: 2"]Item[/TD]
[TD="colspan: 2"][/TD]
[TD]Used[/TD]
[TD]Expire[/TD]
[TD="colspan: 2"]Damage[/TD]
[TD]Item[/TD]
[TD="colspan: 2"][/TD]
[/TR]
[TR]
[TD="colspan: 2"]Order 1[/TD]
[TD="colspan: 2"]1[/TD]
[TD="colspan: 2"][/TD]
[TD][/TD]
[TD]8[/TD]
[TD="colspan: 2"][/TD]
[TD][/TD]
[TD="colspan: 2"][/TD]
[/TR]
[TR]
[TD="colspan: 2"]Order 2[/TD]
[TD="colspan: 2"]2[/TD]
[TD="colspan: 2"][/TD]
[TD]20[/TD]
[TD][/TD]
[TD="colspan: 2"][/TD]
[TD][/TD]
[TD="colspan: 2"][/TD]
[/TR]
[TR]
[TD="colspan: 2"]Order 3[/TD]
[TD="colspan: 2"]3[/TD]
[TD="colspan: 2"][/TD]
[TD]24[/TD]
[TD][/TD]
[TD="colspan: 2"][/TD]
[TD][/TD]
[TD="colspan: 2"][/TD]
[/TR]
</tbody>[/TABLE]