Interactive Form

mgriffen

New Member
Joined
Jun 18, 2014
Messages
4
Hi, I work in a grocery store and I am trying to make a Spreadsheet file to send to my employees that will organize the information related to the products they want to put in our weekly advertisement.

I need a brand name and the number of items from that brand that will be on sale and the related UPC's for those items.
Following the brand name, I want my employee to choose from a drop-down list the number of UPC's they need to enter which will then display that number of blank subfields where they will enter the UPC's for those items before moving on to a new brand etc..

So that when they send me the completed sheet I will have an organized list of all the products and their UPC's that I need to input into our POS system.

Thank you for any help,
Matt.
 

Excel Facts

Highlight Duplicates
Home, Conditional Formatting, Highlight Cells, Duplicate records, OK to add pink formatting to any duplicates in selected range.
Hi, there! Are you thinking about a drop-down that has the numbers 1, 2, 3 .... ? to indicate the number of UPCs people want to enter? There are some drawbacks to that approach. You'll wind up with a long drop-down that may not include all the numbers. What if someone wants to enter 84? Is the drop-down going to be 84 numbers long? And then you'll need a form that fits from one to N boxes, and it will never look nice. Here's a better way.

First, what you have is a one-to-many relationship. That is, for each brand, there are up to "many" UPCs (no particular limit), while each UPC belongs to one and only one brand.

It may be easier to set the brands up in a drop-down and have just one field for the UPC. Then the user selects the brand, enters the UPC, and hits Enter (or clicks OK). The form then puts this info into the spreadsheet, and returns to the user with the same brand selected and a blank field to enter the next UPC.

For this, you would have a Module plus a Form. The form would just collect the data from the user. It's the code in the module that would display the form, get the data the user entered, validate it, and put it in the spreadsheet. You could also make this run automatically by putting the module code in ThisWorkbook, under the Workbook_Open event.

In the end, you'd wind up with a spreadsheet with two columns, like this:
Col ACol B
Row 1Brand
UPC
Row 2Johnson & Johnson143969359
Row 3Johnson & Johnson148604953
Row 4Tropicana449693024
Row 5Kraft948724571
Row 6Kraft953425834
Row 7Kraft926583675

<tbody>
</tbody>
 
Upvote 0

Forum statistics

Threads
1,214,920
Messages
6,122,267
Members
449,075
Latest member
staticfluids

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top