A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Setting Up & Running Reports
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Don't want label and text box to be visible if tax amt. field is 0



 
 
Thread Tools Display Modes
  #1  
Old April 25th, 2006, 07:48 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default Don't want label and text box to be visible if tax amt. field is 0

On a report I am creating an invoice. listed is the an example

Total Product 220.18
Total Freight 506.15
Tax 0.00
Total Due: 726.33

I would like if the tax amount is 0.00 then ONLY to show the Total Due:
$amount

Is there anyway to make the text boxes and labels for the Product,freight
and tax not be visible if tax amount is 0????????

Thanks,
Barb
  #2  
Old April 25th, 2006, 07:59 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default Don't want label and text box to be visible if tax amt. field is 0

Set the CanShrink property of the TaxField and the Section where the Tax
field is located in to Yes.

Change the control source of the Tax field to
=IIf([Tax]=0,Null,[Tax])

Make sure that the name of the Tax Field is not Tax, the same name as the
field in the table, give it a different name, other wise the IIf will give
you NAME#


--
Good Luck
BS"D


"babs" wrote:

On a report I am creating an invoice. listed is the an example

Total Product 220.18
Total Freight 506.15
Tax 0.00
Total Due: 726.33

I would like if the tax amount is 0.00 then ONLY to show the Total Due:
$amount

Is there anyway to make the text boxes and labels for the Product,freight
and tax not be visible if tax amount is 0????????

Thanks,
Barb

  #3  
Old April 25th, 2006, 08:21 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default Don't want label and text box to be visible if tax amt. field

That helps alot but I would ALSO like the Product and freignt labels and text
boxes to be not visible if tax=0. Any way I can do that??????

"Ofer Cohen" wrote:

Set the CanShrink property of the TaxField and the Section where the Tax
field is located in to Yes.

Change the control source of the Tax field to
=IIf([Tax]=0,Null,[Tax])

Make sure that the name of the Tax Field is not Tax, the same name as the
field in the table, give it a different name, other wise the IIf will give
you NAME#


--
Good Luck
BS"D


"babs" wrote:

On a report I am creating an invoice. listed is the an example

Total Product 220.18
Total Freight 506.15
Tax 0.00
Total Due: 726.33

I would like if the tax amount is 0.00 then ONLY to show the Total Due:
$amount

Is there anyway to make the text boxes and labels for the Product,freight
and tax not be visible if tax amount is 0????????

Thanks,
Barb

  #4  
Old April 25th, 2006, 09:02 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default Don't want label and text box to be visible if tax amt. field

In that case lets try someting else, set all this fields can shrink property
to Yes.
On the OnPrint event of the Report write the code

Me.[freignt].Visible = (Me.[Tax] 0)
Me.[Product].Visible = (Me.[Tax] 0)
Me.[Tax].Visible = (Me.[Tax] 0)

--
Good Luck
BS"D


"babs" wrote:

That helps alot but I would ALSO like the Product and freignt labels and text
boxes to be not visible if tax=0. Any way I can do that??????

"Ofer Cohen" wrote:

Set the CanShrink property of the TaxField and the Section where the Tax
field is located in to Yes.

Change the control source of the Tax field to
=IIf([Tax]=0,Null,[Tax])

Make sure that the name of the Tax Field is not Tax, the same name as the
field in the table, give it a different name, other wise the IIf will give
you NAME#


--
Good Luck
BS"D


"babs" wrote:

On a report I am creating an invoice. listed is the an example

Total Product 220.18
Total Freight 506.15
Tax 0.00
Total Due: 726.33

I would like if the tax amount is 0.00 then ONLY to show the Total Due:
$amount

Is there anyway to make the text boxes and labels for the Product,freight
and tax not be visible if tax amount is 0????????

Thanks,
Barb

  #5  
Old April 25th, 2006, 09:43 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default Don't want label and text box to be visible if tax amt. field

I added the code below to the OnOpen event of the Report since on the
properties there is no On Print was getting the error below:

You entered an expression that has No Value



Me.[Prodtotal].Visible = (Me.[Taxamt] 0)
Me.[FreightRate].Visible = (Me.[Taxamt] 0)
Me.[Taxamt].Visible = (Me.[Taxamt] 0)


Not sure how this will also handle the labels to not be visible also if the
tax amt. is 0

did I type a syntax error and or what else do I need??

Thanks,
Barb
"Ofer Cohen" wrote:

In that case lets try someting else, set all this fields can shrink property
to Yes.
On the OnPrint event of the Report write the code

Me.[freignt].Visible = (Me.[Tax] 0)
Me.[Product].Visible = (Me.[Tax] 0)
Me.[Tax].Visible = (Me.[Tax] 0)

--
Good Luck
BS"D


"babs" wrote:

That helps alot but I would ALSO like the Product and freignt labels and text
boxes to be not visible if tax=0. Any way I can do that??????

"Ofer Cohen" wrote:

Set the CanShrink property of the TaxField and the Section where the Tax
field is located in to Yes.

Change the control source of the Tax field to
=IIf([Tax]=0,Null,[Tax])

Make sure that the name of the Tax Field is not Tax, the same name as the
field in the table, give it a different name, other wise the IIf will give
you NAME#


--
Good Luck
BS"D


"babs" wrote:

On a report I am creating an invoice. listed is the an example

Total Product 220.18
Total Freight 506.15
Tax 0.00
Total Due: 726.33

I would like if the tax amount is 0.00 then ONLY to show the Total Due:
$amount

Is there anyway to make the text boxes and labels for the Product,freight
and tax not be visible if tax amount is 0????????

Thanks,
Barb

  #6  
Old April 25th, 2006, 10:04 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default Don't want label and text box to be visible if tax amt. field

The code should be located on the OnPrint event of the section were this
field are placed in.

If the lables are attached to the text box, then this code should hide it
automatically

--
Good Luck
BS"D


"babs" wrote:

I added the code below to the OnOpen event of the Report since on the
properties there is no On Print was getting the error below:

You entered an expression that has No Value



Me.[Prodtotal].Visible = (Me.[Taxamt] 0)
Me.[FreightRate].Visible = (Me.[Taxamt] 0)
Me.[Taxamt].Visible = (Me.[Taxamt] 0)


Not sure how this will also handle the labels to not be visible also if the
tax amt. is 0

did I type a syntax error and or what else do I need??

Thanks,
Barb
"Ofer Cohen" wrote:

In that case lets try someting else, set all this fields can shrink property
to Yes.
On the OnPrint event of the Report write the code

Me.[freignt].Visible = (Me.[Tax] 0)
Me.[Product].Visible = (Me.[Tax] 0)
Me.[Tax].Visible = (Me.[Tax] 0)

--
Good Luck
BS"D


"babs" wrote:

That helps alot but I would ALSO like the Product and freignt labels and text
boxes to be not visible if tax=0. Any way I can do that??????

"Ofer Cohen" wrote:

Set the CanShrink property of the TaxField and the Section where the Tax
field is located in to Yes.

Change the control source of the Tax field to
=IIf([Tax]=0,Null,[Tax])

Make sure that the name of the Tax Field is not Tax, the same name as the
field in the table, give it a different name, other wise the IIf will give
you NAME#


--
Good Luck
BS"D


"babs" wrote:

On a report I am creating an invoice. listed is the an example

Total Product 220.18
Total Freight 506.15
Tax 0.00
Total Due: 726.33

I would like if the tax amount is 0.00 then ONLY to show the Total Due:
$amount

Is there anyway to make the text boxes and labels for the Product,freight
and tax not be visible if tax amount is 0????????

Thanks,
Barb

  #7  
Old April 25th, 2006, 10:36 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default Don't want label and text box to be visible if tax amt. field

Put it on the OnPrint of the section.

However, Getting all text boxes not visible even if there IS a taxamt.
Also the labels are still there. these text boxes are sums for
example-maybe that is some of the reason - how do I tie the labels into the
text box.

Name of text box is taxamt
Control source for taxamt is =sum([taxamt])

Code that doesn't seem to work??
Me.Prodtotal.Visible = (Me.[Taxamt] 0)
Me.FreightRate.Visible = (Me.[Taxamt] 0)
Me.Taxamt.Visible = (Me.[Taxamt] 0)

"Ofer Cohen" wrote:

The code should be located on the OnPrint event of the section were this
field are placed in.

If the lables are attached to the text box, then this code should hide it
automatically

--
Good Luck
BS"D


"babs" wrote:

I added the code below to the OnOpen event of the Report since on the
properties there is no On Print was getting the error below:

You entered an expression that has No Value



Me.[Prodtotal].Visible = (Me.[Taxamt] 0)
Me.[FreightRate].Visible = (Me.[Taxamt] 0)
Me.[Taxamt].Visible = (Me.[Taxamt] 0)


Not sure how this will also handle the labels to not be visible also if the
tax amt. is 0

did I type a syntax error and or what else do I need??

Thanks,
Barb
"Ofer Cohen" wrote:

In that case lets try someting else, set all this fields can shrink property
to Yes.
On the OnPrint event of the Report write the code

Me.[freignt].Visible = (Me.[Tax] 0)
Me.[Product].Visible = (Me.[Tax] 0)
Me.[Tax].Visible = (Me.[Tax] 0)

--
Good Luck
BS"D


"babs" wrote:

That helps alot but I would ALSO like the Product and freignt labels and text
boxes to be not visible if tax=0. Any way I can do that??????

"Ofer Cohen" wrote:

Set the CanShrink property of the TaxField and the Section where the Tax
field is located in to Yes.

Change the control source of the Tax field to
=IIf([Tax]=0,Null,[Tax])

Make sure that the name of the Tax Field is not Tax, the same name as the
field in the table, give it a different name, other wise the IIf will give
you NAME#


--
Good Luck
BS"D


"babs" wrote:

On a report I am creating an invoice. listed is the an example

Total Product 220.18
Total Freight 506.15
Tax 0.00
Total Due: 726.33

I would like if the tax amount is 0.00 then ONLY to show the Total Due:
$amount

Is there anyway to make the text boxes and labels for the Product,freight
and tax not be visible if tax amount is 0????????

Thanks,
Barb

  #8  
Old April 26th, 2006, 03:15 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default Don't want label and text box to be visible if tax amt. field

Anyone have any ideas - need help!!! Of course was supposed to be done
yesterday??

"babs" wrote:

Put it on the OnPrint of the section.

However, Getting all text boxes not visible even if there IS a taxamt.
Also the labels are still there. these text boxes are sums for
example-maybe that is some of the reason - how do I tie the labels into the
text box.

Name of text box is taxamt
Control source for taxamt is =sum([taxamt])

Code that doesn't seem to work??
Me.Prodtotal.Visible = (Me.[Taxamt] 0)
Me.FreightRate.Visible = (Me.[Taxamt] 0)
Me.Taxamt.Visible = (Me.[Taxamt] 0)

"Ofer Cohen" wrote:

The code should be located on the OnPrint event of the section were this
field are placed in.

If the lables are attached to the text box, then this code should hide it
automatically

--
Good Luck
BS"D


"babs" wrote:

I added the code below to the OnOpen event of the Report since on the
properties there is no On Print was getting the error below:

You entered an expression that has No Value



Me.[Prodtotal].Visible = (Me.[Taxamt] 0)
Me.[FreightRate].Visible = (Me.[Taxamt] 0)
Me.[Taxamt].Visible = (Me.[Taxamt] 0)


Not sure how this will also handle the labels to not be visible also if the
tax amt. is 0

did I type a syntax error and or what else do I need??

Thanks,
Barb
"Ofer Cohen" wrote:

In that case lets try someting else, set all this fields can shrink property
to Yes.
On the OnPrint event of the Report write the code

Me.[freignt].Visible = (Me.[Tax] 0)
Me.[Product].Visible = (Me.[Tax] 0)
Me.[Tax].Visible = (Me.[Tax] 0)

--
Good Luck
BS"D


"babs" wrote:

That helps alot but I would ALSO like the Product and freignt labels and text
boxes to be not visible if tax=0. Any way I can do that??????

"Ofer Cohen" wrote:

Set the CanShrink property of the TaxField and the Section where the Tax
field is located in to Yes.

Change the control source of the Tax field to
=IIf([Tax]=0,Null,[Tax])

Make sure that the name of the Tax Field is not Tax, the same name as the
field in the table, give it a different name, other wise the IIf will give
you NAME#


--
Good Luck
BS"D


"babs" wrote:

On a report I am creating an invoice. listed is the an example

Total Product 220.18
Total Freight 506.15
Tax 0.00
Total Due: 726.33

I would like if the tax amount is 0.00 then ONLY to show the Total Due:
$amount

Is there anyway to make the text boxes and labels for the Product,freight
and tax not be visible if tax amount is 0????????

Thanks,
Barb

  #9  
Old April 26th, 2006, 03:35 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default Don't want label and text box to be visible if tax amt. field

1.
Ti link the lable to the TextBox follow this steps
1.1 Select a lable and Cut it (Ctrl+X)
1.2 Select the text box you want to link the lable to
1.3 Paste (ctrl + v)
Now the lable should be linked to the text box, do the same to all of the
lables

2.
If the Tax Text field name is taxamt and in it control source it say
=Sum([taxamt])
Change the name of this text field to taxamt_text, and try the code

Me.Prodtotal.Visible = (Me.[taxamt_text] 0)
Me.FreightRate.Visible = (Me.[taxamt_text] 0)
Me.Taxamt.Visible = (Me.[taxamt_text] 0)

I hope that helped
--
Good Luck
BS"D


"babs" wrote:

Anyone have any ideas - need help!!! Of course was supposed to be done
yesterday??

"babs" wrote:

Put it on the OnPrint of the section.

However, Getting all text boxes not visible even if there IS a taxamt.
Also the labels are still there. these text boxes are sums for
example-maybe that is some of the reason - how do I tie the labels into the
text box.

Name of text box is taxamt
Control source for taxamt is =sum([taxamt])

Code that doesn't seem to work??
Me.Prodtotal.Visible = (Me.[Taxamt] 0)
Me.FreightRate.Visible = (Me.[Taxamt] 0)
Me.Taxamt.Visible = (Me.[Taxamt] 0)

"Ofer Cohen" wrote:

The code should be located on the OnPrint event of the section were this
field are placed in.

If the lables are attached to the text box, then this code should hide it
automatically

--
Good Luck
BS"D


"babs" wrote:

I added the code below to the OnOpen event of the Report since on the
properties there is no On Print was getting the error below:

You entered an expression that has No Value



Me.[Prodtotal].Visible = (Me.[Taxamt] 0)
Me.[FreightRate].Visible = (Me.[Taxamt] 0)
Me.[Taxamt].Visible = (Me.[Taxamt] 0)


Not sure how this will also handle the labels to not be visible also if the
tax amt. is 0

did I type a syntax error and or what else do I need??

Thanks,
Barb
"Ofer Cohen" wrote:

In that case lets try someting else, set all this fields can shrink property
to Yes.
On the OnPrint event of the Report write the code

Me.[freignt].Visible = (Me.[Tax] 0)
Me.[Product].Visible = (Me.[Tax] 0)
Me.[Tax].Visible = (Me.[Tax] 0)

--
Good Luck
BS"D


"babs" wrote:

That helps alot but I would ALSO like the Product and freignt labels and text
boxes to be not visible if tax=0. Any way I can do that??????

"Ofer Cohen" wrote:

Set the CanShrink property of the TaxField and the Section where the Tax
field is located in to Yes.

Change the control source of the Tax field to
=IIf([Tax]=0,Null,[Tax])

Make sure that the name of the Tax Field is not Tax, the same name as the
field in the table, give it a different name, other wise the IIf will give
you NAME#


--
Good Luck
BS"D


"babs" wrote:

On a report I am creating an invoice. listed is the an example

Total Product 220.18
Total Freight 506.15
Tax 0.00
Total Due: 726.33

I would like if the tax amount is 0.00 then ONLY to show the Total Due:
$amount

Is there anyway to make the text boxes and labels for the Product,freight
and tax not be visible if tax amount is 0????????

Thanks,
Barb

  #10  
Old April 26th, 2006, 05:37 PM posted to microsoft.public.access.reports
external usenet poster
 
Posts: n/a
Default Don't want label and text box to be visible if tax amt. field

I linked the labels. Thanks didn't know that. I labels and text boxes
disappear when tax amount is 0. However, the only thing that shows up when
tax amount is not 0 is the Label for Product total?????? with no prodtotal
value and no tax amt. The overall total reflects the tax in there. Tried to
originally set the text boxes as visible and not visible - still get the same
result. Also third line of code below had to put
me.taxamt_text - not sure if right - was sending me to debut and didn't
recognize taxamt - by itself.




Me.Prodtotal.Visible = (Me.[Taxamt_text] 0)
Me.FreightRate.Visible = (Me.[Taxamt_text] 0)
Me.Taxamt_text.Visible = (Me.[Taxamt_text] 0)


Any ideas?????? seems like we're getting close????

"Ofer Cohen" wrote:

1.
Ti link the lable to the TextBox follow this steps
1.1 Select a lable and Cut it (Ctrl+X)
1.2 Select the text box you want to link the lable to
1.3 Paste (ctrl + v)
Now the lable should be linked to the text box, do the same to all of the
lables

2.
If the Tax Text field name is taxamt and in it control source it say
=Sum([taxamt])
Change the name of this text field to taxamt_text, and try the code

Me.Prodtotal.Visible = (Me.[taxamt_text] 0)
Me.FreightRate.Visible = (Me.[taxamt_text] 0)
Me.Taxamt.Visible = (Me.[taxamt_text] 0)

I hope that helped
--
Good Luck
BS"D


"babs" wrote:

Anyone have any ideas - need help!!! Of course was supposed to be done
yesterday??

"babs" wrote:

Put it on the OnPrint of the section.

However, Getting all text boxes not visible even if there IS a taxamt.
Also the labels are still there. these text boxes are sums for
example-maybe that is some of the reason - how do I tie the labels into the
text box.

Name of text box is taxamt
Control source for taxamt is =sum([taxamt])

Code that doesn't seem to work??
Me.Prodtotal.Visible = (Me.[Taxamt] 0)
Me.FreightRate.Visible = (Me.[Taxamt] 0)
Me.Taxamt.Visible = (Me.[Taxamt] 0)

"Ofer Cohen" wrote:

The code should be located on the OnPrint event of the section were this
field are placed in.

If the lables are attached to the text box, then this code should hide it
automatically

--
Good Luck
BS"D


"babs" wrote:

I added the code below to the OnOpen event of the Report since on the
properties there is no On Print was getting the error below:

You entered an expression that has No Value



Me.[Prodtotal].Visible = (Me.[Taxamt] 0)
Me.[FreightRate].Visible = (Me.[Taxamt] 0)
Me.[Taxamt].Visible = (Me.[Taxamt] 0)


Not sure how this will also handle the labels to not be visible also if the
tax amt. is 0

did I type a syntax error and or what else do I need??

Thanks,
Barb
"Ofer Cohen" wrote:

In that case lets try someting else, set all this fields can shrink property
to Yes.
On the OnPrint event of the Report write the code

Me.[freignt].Visible = (Me.[Tax] 0)
Me.[Product].Visible = (Me.[Tax] 0)
Me.[Tax].Visible = (Me.[Tax] 0)

--
Good Luck
BS"D


"babs" wrote:

That helps alot but I would ALSO like the Product and freignt labels and text
boxes to be not visible if tax=0. Any way I can do that??????

"Ofer Cohen" wrote:

Set the CanShrink property of the TaxField and the Section where the Tax
field is located in to Yes.

Change the control source of the Tax field to
=IIf([Tax]=0,Null,[Tax])

Make sure that the name of the Tax Field is not Tax, the same name as the
field in the table, give it a different name, other wise the IIf will give
you NAME#


--
Good Luck
BS"D


"babs" wrote:

On a report I am creating an invoice. listed is the an example

Total Product 220.18
Total Freight 506.15
Tax 0.00
Total Due: 726.33

I would like if the tax amount is 0.00 then ONLY to show the Total Due:
$amount

Is there anyway to make the text boxes and labels for the Product,freight
and tax not be visible if tax amount is 0????????

Thanks,
Barb

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Return SEARCHED Column Number of Numeric Label and Value Sam via OfficeKB.com Worksheet Functions 23 January 30th, 2006 06:16 PM
Use label captions to get query field data [email protected] Setting Up & Running Reports 3 November 14th, 2005 12:23 AM
Creating dynamic cross reference links in a Word document torajudo General Discussion 4 October 25th, 2005 03:51 PM
Label does not show below a text box with a Can Grow property of y ChuckW Setting Up & Running Reports 3 August 4th, 2005 02:13 AM
Ideas On Producing Envelopes & Labels For Data RNUSZ@OKDPS Setting Up & Running Reports 0 April 28th, 2005 03:22 PM


All times are GMT +1. The time now is 08:21 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.