I'm creating a little POS, I'm trying to create a form with let's say 20
command buttons, this will represent the 20 most sold products, (this will
come from a query) each product has its own UPC code, the most sold will be
first and so on, so the buttons on the form will be like this:
Command1= The first record on this query, wth the UPC or DESCRIPTION od the
product as it Caption.
Command2= The second record on this query, wth the UPC or DESCRIPTION od the
product as it Caption.
and so on, untill the 20th
If you REALLY REALLY need the Command Button interface then you'll just need
to create twenty command buttons... but might I suggest a Listbox as an
alternative? If you base it on a query showing the Description, with the UPC
as the bound column, you can do this with very little or no code.
With command buttons you'll need VBA code (in the form's Load event probably)
to open a recordset based on the query, loop through it, and set the Caption
property of each of 20 command buttons (named cmdProduct1, cmdProduct2 and so
on). Timeconsuming, and it would prevent you from using the preferred MDE
format for the frontend since you can't (IIRC) make form design changes in a
MDE.