Full Version: Guidance on how to separate records into controls on a form
UtterAccess Forums > Microsoft® Access > Access Forms
oodle
Hi Developers,
I'd just like some guidance as to how to do something like this....
In a table (tFeelings), I have about 275 records, simply types of feelings or emotions, like happy, sad, mad, and so-on. On a form, the desired functionality would be similar to a multi-select listbox duplicated over and over (275 times), with each listbox's default value being the autonum of a feeling from tFeelings and sized to show only that particular feeling. The user could select multiple feelings by selecting multiple listboxes, and this would build a string of the selected feelings. The string could then be stored for today's date, and the feelings could be outputted in a report.
The challenge is that the controls to select each feeling must be separated. Is something like this possible? If so, I would sincerely and greatly appreciate any help.
Thanks
iconfused.gif
theDBguy
Hi,
welcome2UA.gif
Are you saying that you want a form with 275 listboxes? That seems to be a lot. Can you please explain why the setup has to be that way?
I'm just curious...
missinglinq
Sorry, but to be perfectly honest, having a form with 275 Listboxes would simply be unusable.
here's no reason that you can't do this with a single Listbox with the Multi-Select Property set to Simple or Extended.
In version 2007/3020 you could use a Combobox set the same way to do the same thing. With 275 items a Combobox would be much more practical.
With code you could even use a Combobox in versions prior to 2007.
Having said this, having a single control holding multiple pieces of data, i.e. "feelings," smacks of improper, non-normalized database design.
HAs DBGuy said, you need to explain why you think you need it set up like this.
Linq ;0)>
oodle
Thanks for replying missinglinq and the DBguy,
Trust me on the part of normalizing data--I'm aware of the strangeness of this setup. It seems like I often want to do the impossible with Access/VB, and, through browsing great forums such as this one, I realize that the impossible is usually possible.
I was actually going to categorize or separate all of these controls on about 10 different tabbed pages on a form. The reason for wanting to physically separate these controls though is because I've inserted emoticons or smilies (gif files using gif89.dll) throughout the tabbed pages. The smilies work, but I'm not sure how to have users select a text record that represents the smilies.
For instance, next to a curious smiley, I'd have the record 'curious' visible in a control that a user could simply click on to select. Next to a confused smiley, there would be a 'confused' control that a user could click. Therefore, a user could click one or more than one control.
Because there are so many, and because some smilies are rather large, I'd like there to be physical space between the controls.
How could the combo box work?
ace
Leaving behind the obvious normalization problems, have you considered
using checkbox controls placed next to the images?
theDBguy
... or, I might even try using toggle buttons with the images on top of them.
Just my 2 cents...
This is a "lo-fi" version of UA. To view the full version with more information, formatting and images, please click here.