Thank you Duane -You have answered my question but, of course I have
some
more text boxes and labels that I have to have on report, so I was
wondering
if you could help here, too.
When I try to add another text box a label I get following error.
http://adnani.8m.com/Sample1.JPG
What I want is this report:
http://adnani.8m.com/Sample2.JPG
Thank you very much ? Thank you Crystal, too. I find your help harder
to
implement, again thank you!
Adnan
--
Please post all your inquiries on this community so we can all
benefit -
Thank you!
:
I think you should remove the borders and use the Line Method in the
On
Print event of the report section to draw the borders.
Assuming you have a text box "PR_DESC" that can grow or shrink. The
label
next to it is "Label0" and you want to print a border around it the
same
height as the grown PR_DESC text box. Enter code into the On Print
event
of
the report section:
Private Sub Detail_Print(Cancel As Integer, PrintCount As Integer)
Dim lngHeight As Long
lngHeight = Me.PR_DESC.Height
Me.Line (Me.Label0.Left, Me.Label0.Top) _
-Step(Me.Label0.Width, lngHeight), , B
End Sub
If you have other controls, you may need to find the maximum height
and
draw
borders around all controls.
--
Duane Hookom
MS Access MVP
Thank you, Crystal - I'm not that advances with access, therefore
could
you
point this out on where to paste this formula?
Should I change label to Tex then paste this
"IIF(Isnull([field]),"","Label:
" &
[field])" on RecordSource or how?
Little bit more info please.
Reminder: what I want is, the label to grow/shrink when its
associated
filed
shirks, I want their frames/borders look alike on size.
Again, thank you for quick response,
Adnan, Computer science student, Kosovo
--
Please post all your inquiries on this community so we can all
benefit -
Thank you!
:
Hi Adnan,
instead of using labels, you could make the label caption
part of the field value. Do this in the RecordSource. For
example...
field --> Fieldname_: IIF(Isnull([field]),"","Label: " &
[field])
Another option is to make the labels invisible in code for
the controls that have no data
Warm Regards,
Crystal
Microsoft Access MVP 2006
*
Have an awesome day
remote programming and training
strive4peace2006 at yahoo.com
*
Adnan wrote:
Greetings****
Why the associated label will not grow/shrink stimulatingly as
the
text
does? I have several text boxes that grow/shrink based on the
amount
of
data,
I would ant the associated labels to shrink/grow as they do. How
would
I do
this? Please help?
Thank you, Adnan