Header on each page

  • Thread starter Thread starter cmweb via AccessMonster.com
  • Start date Start date
C

cmweb via AccessMonster.com

I've designed a report with a header which has a special title that it
depends on a previous form's textbox
In the header page I used a textbox with:

=Forms![formname]![controlname]

This works fine on the first page. However next pages displays an error:
# name
I need show the title on every page.

Thanks in advance,
CM
 
try setting the value of the unbound textbox control's ControlSource
property in the report's Open event procedure, as

Private Sub Report_Open(Cancel As Integer)

Me!TextboxName.ControlSource = "='" _
& Forms!FormName!FieldName & "'"

End Sub

hth
 
Hi Tina
Your answer was correct and very useful for me. You are an angel

I have a new related question, I created a form and a report with:

Form: frmTest
Texbox: monthx
Texbox yearx

Report: infTest
Textbox: period

If I would show in the report, for example: "February / 2006" , (the
concatenation :monthx+yearx)

In the report's Open event procedure:

Private Sub Report_Open(Cancel As Integer)
Me!period.ControlSource = "='" & Forms!frmTest!monthx & "'" + "/" & Forms!
frmTest!yearx & "'"
End Sub

but It gave me a sintaxis error.

Thanks
Carlos
 
try

Private Sub Report_Open(Cancel As Integer)
Me!period.ControlSource = "='" & Forms!frmTest!monthx & "/" & Forms!
frmTest!yearx & "'"
End Sub

hth
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top