Combining Fields 
November 13th, 2005, 06:20 AM
| | | |
I have a Combo Box (Fiield 2 is the seen one, field 1 is the bound one)
and I want to combine it with another field on a report. The new field
should only be visible whenever the Amount field is greater than 0.
How would I accomplish this?
Thanks
DS | 
November 13th, 2005, 06:21 AM
| | | | re: Combining Fields
On Tue, 14 Dec 2004 10:04:57 -0500, DS <bootybox@optonline.net> wrote:
[color=blue]
>I have a Combo Box (Fiield 2 is the seen one, field 1 is the bound one)
>and I want to combine it with another field on a report. The new field
>should only be visible whenever the Amount field is greater than 0.
>How would I accomplish this?
>Thanks
>DS[/color]
Hi
This is not very clear.
Since a space is invisible, you can set a control to have the
controlsource
=iif([Amount]>0, xxxx, " ")
where xxx is whatever you want to be visible.
David | 
November 13th, 2005, 06:23 AM
| | | | re: Combining Fields
David Schofield wrote:[color=blue]
> On Tue, 14 Dec 2004 10:04:57 -0500, DS <bootybox@optonline.net> wrote:
>
>[color=green]
>>I have a Combo Box (Fiield 2 is the seen one, field 1 is the bound one)
>>and I want to combine it with another field on a report. The new field
>>should only be visible whenever the Amount field is greater than 0.
>>How would I accomplish this?
>>Thanks
>>DS[/color]
>
> Hi
> This is not very clear.
> Since a space is invisible, you can set a control to have the
> controlsource
> =iif([Amount]>0, xxxx, " ")
> where xxx is whatever you want to be visible.
> David
>[/color]
What it is, is this. The first field is a combo box that yields a
percent number, 10%, 15% etc. The second field is a field that says,
Family Discount, Manager Discount, etc. Also a combo box, both boxes
are bound to field 1 and display field 2. What I want to do is a third
field, unbound that would give me the result of field 1 and 2 combined.
Example: Family Discount 10%, Manager Discount 10%, etc. If there
is no percentage Family Discount, Manager Discount etc...there are
several combinations but that shouldn't matter.
Thanks DS | 
November 13th, 2005, 06:23 AM
| | | | re: Combining Fields
How about setting the form's On Current event to something like
ComboBox3 = ComboBox2.Column(1) & " " & ComboBox1.Column(1)
Column counts start at 0 so column 1 is the 2nd column. You can also
include some code to check if either of the ComboBox fields are null
before populating ComboBox3.
Hope this helps ... Good luck!! | 
November 13th, 2005, 06:23 AM
| | | | re: Combining Fields
Koontzie wrote:
[color=blue]
> How about setting the form's On Current event to something like
> ComboBox3 = ComboBox2.Column(1) & " " & ComboBox1.Column(1)
>
> Column counts start at 0 so column 1 is the 2nd column. You can also
> include some code to check if either of the ComboBox fields are null
> before populating ComboBox3.
>
> Hope this helps ... Good luck!!
>[/color]
GOT IT!
Its Format([Discount P],"##%")
Thank You Once Again
DS | 
November 13th, 2005, 06:23 AM
| | | | re: Combining Fields
On 15 Dec 2004 11:56:07 -0800, "Koontzie" <creffner@shbm.com> wrote:
[color=blue]
>How about setting the form's On Current event to something like
>ComboBox3 = ComboBox2.Column(1) & " " & ComboBox1.Column(1)
>
>Column counts start at 0 so column 1 is the 2nd column. You can also
>include some code to check if either of the ComboBox fields are null
>before populating ComboBox3.
>
>Hope this helps ... Good luck!!
>[/color]
Is this on a form or a report? On a form you would need to also put
this code in the afterupdate event of each of the combo boxes
David | 
November 13th, 2005, 06:24 AM
| | | | re: Combining Fields
David Schofield wrote:
[color=blue]
> Is this on a form or a report? On a form you would need to also put
> this code in the afterupdate event of each of the combo boxes
> David[/color]
That draws my attention: if you want all controls on a form to share
certain behavior, you can see the WithEvents article on my site.
--
Bas Cost Budde, Holland http://www.heuveltop.nl/BasCB/msac_index.html
I prefer human mail above automated so in my address
replace the queue with a tea |  | | | | /bytes/about
We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights.
Get the best answers to your questions from over 225,702 network members.
|