ms access - List a row of data in a listbox / combobox -
i have listbox displays result of query. how database has been designed information in rows there magnitude of possible controls 1 product.
i.e
productname | control 1 | control 2 | control 3 | control 4 | control 5 ........ | control 14
product 1 | 010101010 | 101010101 | ..........
i list box show column heads on left rather top, or combo box list part no's.
is property issue or done through vba?
so, combobox on 1 of projects' main screens, utilize table row source. (technically it's query suppose it's 2 fields table)
i have table looks this:
+--------------+----------------+ | quickentryid | quickentryname | +-------------------------------+ | 1 | add part | | 2 | add control | | 3 | add product | +--------------+----------------+
(all of can done behind scenes making few selections in wizard.)
i use select
statement populate combobox table. when right clicking on combobox, in data
tab, there row source
, put query.
select [quickentrylaunchtbl].[quickentryid], [quickentrylaunchtbl].[quickentryname] quickentrylaunchtbl order [quickentryname];
i format column widths, under format
tab: 0";1"
(or when create combobox, 1 of steps checkbox "hide id field (recommended)" , select that.
you should never have try , arrange column name row source combobox, because that's not actual data. now, if there table this:
+--------------+----------------+ | partid | partnumber | +-------------------------------+ | 1 | 010101010 | | 2 | 110101010 | | 3 | 210101010 | +--------------+----------------+
then combobox show partnumber in drop down list, , usable data.
i guess create table column names rows, i'm not sure use be.
Comments
Post a Comment