Hello,
I have a report which uses a subreport. When I run the report, I get "Enter Parameter Value" error message for "tblGuestRoom". I click ok and the report seems to work fine.
I have narrowed down this error to the Link Master Fields property setting by setting up the exact same scenario with a form instead of a report. That way, the error message is more precise, and is 'The Link Master fields property setting has produced this error: The object doesn't contain the Automation object 'tblGuestRoom'.
Here is the picture of how things are set up:
--Main report is "rptReport1". RecordSource is "qryQuery1", which uses 2 tables: tblGuestRoom, the table coming up in the error, and tblBathroom. They both have primary key of RoomNumber.
--Subreport is "rsubReport1". RecordSource is tblWindow. From tblGuestRoom to tblWindow is a one-to-many relationship, on key RoomNumber. The idea is to display one report page per room number, with the subreport displaying window 1, window 2, etc., per room number. When I tested this using forms, the error came up when I attempted to scroll to window 3, for a room with only 2 windows. I think the problem lies right here. Perhaps I didn't set my relationships up correctly, Link Master, and it doesn't know the one-to-many relationship?? (although seems to be displaying fine).
On the main report, properties for subreport are as follows: SourceObject = the subreport. I set up Link Child Fields (tblBed.RoomNumber), and Link Master Fields (tblGuestRoom.RoomNumber). In Relationships, there is a 1 to many relationship between tblGuestRoom and tblBed. Does the subreport know this, or do I need to tell it that somehow? Where do I tell it this? I suspect that this is where my problem lies.
Thank you in advance for any help,
Lori
I have a report which uses a subreport. When I run the report, I get "Enter Parameter Value" error message for "tblGuestRoom". I click ok and the report seems to work fine.
I have narrowed down this error to the Link Master Fields property setting by setting up the exact same scenario with a form instead of a report. That way, the error message is more precise, and is 'The Link Master fields property setting has produced this error: The object doesn't contain the Automation object 'tblGuestRoom'.
Here is the picture of how things are set up:
--Main report is "rptReport1". RecordSource is "qryQuery1", which uses 2 tables: tblGuestRoom, the table coming up in the error, and tblBathroom. They both have primary key of RoomNumber.
--Subreport is "rsubReport1". RecordSource is tblWindow. From tblGuestRoom to tblWindow is a one-to-many relationship, on key RoomNumber. The idea is to display one report page per room number, with the subreport displaying window 1, window 2, etc., per room number. When I tested this using forms, the error came up when I attempted to scroll to window 3, for a room with only 2 windows. I think the problem lies right here. Perhaps I didn't set my relationships up correctly, Link Master, and it doesn't know the one-to-many relationship?? (although seems to be displaying fine).
On the main report, properties for subreport are as follows: SourceObject = the subreport. I set up Link Child Fields (tblBed.RoomNumber), and Link Master Fields (tblGuestRoom.RoomNumber). In Relationships, there is a 1 to many relationship between tblGuestRoom and tblBed. Does the subreport know this, or do I need to tell it that somehow? Where do I tell it this? I suspect that this is where my problem lies.
Thank you in advance for any help,
Lori