![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Hi I have a Main Form with Subform I have a Report that opens on a query that restricts it to a single record On the report there are Labels whose captions I need to alter depending what records are showing on the subform. But I am only getting it to work on the first Label. Grateful for any help Private Sub Report_Open(Cancel As Integer) DoCmd.Maximize If Forms![frmSite]![zfrmSiteProductLeft].Form![ComboProductID] = 1 Then Me.lbl_1.Caption = 9 End If If Forms![frmSite]![zfrmSiteProductLeft].Form![ComboProductID] = 2 Then Me.lbl_2.Caption = 9 End If If Forms![frmSite]![zfrmSiteProductLeft].Form![ComboProductID] = 3 Then Me.lbl_3.Caption = 9 End If If Forms![frmSite]![zfrmSiteProductLeft].Form![ComboProductID] = 4 Then Me.lbl_4.Caption = 9 End Sub |
#3
| |||
| |||
|
#4
| |||
| |||
|
|
Hi Thanks for the reply The Database is for a Vending Machine operator who has 12 different Products available to leave at each of the vending machine sites Each site can only take 9 choices of Product And each choice of product = 9 items left on sitehence the caption = 9 This Report is for the vending roundsman to print out and take on his rounds and manually write on the paper how many have been sold. The data showing which Products have been left on the previous visit, are on the underlying subform The result on the report should look something like this: Site: Jones the Butchers Address: 1 High Street, Romford, Essex RM1 1FT Tel # 01111 111222 Products Left at site last visit Chocolate Bars 9 Peanut Bars 9 Peppermint Bars 9 Honeycombe Bars 0 Raisin Bars 9 Chocolate wraps 0 Candy Fizz 9 Whirlygigs 9 CHocolate Balls 0 Candy Balls 9 Apricot Bars 9 Maltesers 9 |
![]() |
| Thread Tools | |
| Display Modes | |
| |