Header on each page

  • Thread starter cmweb via AccessMonster.com
  • 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
 
T

tina

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
 
C

cmweb via AccessMonster.com

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
 
T

tina

try

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

hth
 
Top