Use of can shrink

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am working with Microsoft 2000 and have 2 currency fields on an invoice
that are not required by most clients: labor and material costs. I'm using
the can shrink property = yes. Names of field are Text44 and Text45,
control sources are ="Labor: "+[Labor] and ="Material: "+[Material]. It
works perfect when the fields are 0 but when populated it gives me an error
"#error" where the fields would print. I've read all the posts available on
the subject and have tried various suggestions but can't make it work. I've
also made the height of fields .0007 and made can grow = yes but that didn't
work.
Thanks for your attention in the matter,
JIM
 
Jim,

I am not really sure what the problem is here, but I don't think it is
realted at all to the Can Grow and Can Shrink properties.

What happens if you try this experiment?...
="Labor: " & Format([Labor])
 
Steve Schapel said:
Jim,

I am not really sure what the problem is here, but I don't think it is
realted at all to the Can Grow and Can Shrink properties.

What happens if you try this experiment?...
="Labor: " & Format([Labor])

--
Steve Schapel, Microsoft Access MVP
I am working with Microsoft 2000 and have 2 currency fields on an invoice
that are not required by most clients: labor and material costs. I'm using
the can shrink property = yes. Names of field are Text44 and Text45,
control sources are ="Labor: "+[Labor] and ="Material: "+[Material]. It
works perfect when the fields are 0 but when populated it gives me an error
"#error" where the fields would print. I've read all the posts available on
the subject and have tried various suggestions but can't make it work. I've
also made the height of fields .0007 and made can grow = yes but that didn't
work.
Thanks for your attention in the matter,
JIM
 
Thanks, I tried what you suggested and my report records "Labor: 260", which
is correct. But now, when Labor is 0 on other invoices it prints "Labor:"
which I want eliminated. How do I eliminate the unwanted lines of Labor and
material when 0?
Thanks for your attention, JIM

Steve Schapel said:
Jim,

I am not really sure what the problem is here, but I don't think it is
realted at all to the Can Grow and Can Shrink properties.

What happens if you try this experiment?...
="Labor: " & Format([Labor])

--
Steve Schapel, Microsoft Access MVP
I am working with Microsoft 2000 and have 2 currency fields on an invoice
that are not required by most clients: labor and material costs. I'm using
the can shrink property = yes. Names of field are Text44 and Text45,
control sources are ="Labor: "+[Labor] and ="Material: "+[Material]. It
works perfect when the fields are 0 but when populated it gives me an error
"#error" where the fields would print. I've read all the posts available on
the subject and have tried various suggestions but can't make it work. I've
also made the height of fields .0007 and made can grow = yes but that didn't
work.
Thanks for your attention in the matter,
JIM
 
Jim,

Try it like this...
=IIf([Labor]=0,Null,"Labor: " & Format([Labor],"currency"))
 
.... or, when you say "Labor is 0", do you really mean the value of the
Labor field is already Null? If so...
=IIf(IsNull([Labor]),Null,"Labor: " & Format([Labor],"currency"))
or...
=IIf(Nz([Labor],0)=0,Null,"Labor: " & Format([Labor],"currency"))
 
Thanks so much, Steve. I used the Nz option as field was null. It works
great don't even need can shrink. jim

Steve Schapel said:
.... or, when you say "Labor is 0", do you really mean the value of the
Labor field is already Null? If so...
=IIf(IsNull([Labor]),Null,"Labor: " & Format([Labor],"currency"))
or...
=IIf(Nz([Labor],0)=0,Null,"Labor: " & Format([Labor],"currency"))

--
Steve Schapel, Microsoft Access MVP

Steve said:
Jim,

Try it like this...
=IIf([Labor]=0,Null,"Labor: " & Format([Labor],"currency"))
 
Back
Top