Sub Report Repeating

D

dan.cawthorne

With On My Main Report I have a Sup Report,

The Main Reports Shows The Project Number. Project Title and Enquiry:
Enquiry Could Be Anything From "Supply Only Ductwork"

The Sub-Report Shows All The Drawings That Are Needed For That
Enquiry, The Sub-Report Is Set to a Contineuos Type,

The Problem Arise's If Ive Seletced The Say 2 or more Companys For
that Enquiry,

What Is Happening The Sub Report Is Duplicating The Drawing List For
How Many Companys Ive Set The Enquiry To.

Is The Away I Can Just Print the One Set of Drawings for that Enquiry
Records, and Not Repeat the Whole Set?

Ive Tried Going into the Sub-form Properties and Selecting The 2
Fields and in the list ive gone to Hide Duplications and set that to
YES and Nothink Is Happening.


Any Help Available?
 
M

Marshall Barton

With On My Main Report I have a Sup Report,

The Main Reports Shows The Project Number. Project Title and Enquiry:
Enquiry Could Be Anything From "Supply Only Ductwork"

The Sub-Report Shows All The Drawings That Are Needed For That
Enquiry, The Sub-Report Is Set to a Contineuos Type,

The Problem Arise's If Ive Seletced The Say 2 or more Companys For
that Enquiry,

What Is Happening The Sub Report Is Duplicating The Drawing List For
How Many Companys Ive Set The Enquiry To.

Is The Away I Can Just Print the One Set of Drawings for that Enquiry
Records, and Not Repeat the Whole Set?

Ive Tried Going into the Sub-form Properties and Selecting The 2
Fields and in the list ive gone to Hide Duplications and set that to
YES and Nothink Is Happening.


How do companies fit into the report? In the main report or
in the subreport?

Is there any grouping in either report?

At this point, all I can do is guess that the recotd source
query for one of the reports contains a inappropriate Join.
 
D

dan.cawthorne

How do companies fit into the report? In the main report or
in the subreport?

Is there any grouping in either report?

At this point, all I can do is guess that the recotd source
query for one of the reports contains a inappropriate Join.

Well The Main Report Source Is a Query, The Same Query That Used to
Create My Mail Merge. Records Only Appear In The Mail merge Query,
Once An Enquiry is Created Note On Enquiry Form i have a continuous
Subform which i can assign Drawings To the Enquiry, The Link Field On
The Main Form and Subform is [Enquiry No] and also have a [ProjectQNo]
look Combo on the Form that I can Select a Project then i pop along to
a company form, go to a 3rd tab which has a subform on it, The Subform
is Related to a Table Called Enquiry Link, Which has 2 Primary Keys,
[ProjectQno] and [Enquiry No] Plus Specific Information Date Received,
Quote Used. Etc, Which the table enable me to have mutiply Enquirys
Per Project, or Same Enquiry and Company But Different Project.

When I Select the [Enquiry No] From the Dropdown On The Enquiry Link
Form, its assigns that Enquiry No To The Company ID

Once thats Then Assigned The Record will Show Up in The MailMerge
Query.

Which i could have 4 Records In That Query Which are all The Same
Enquiry The Only This Is Different is The Company ID, on Each Record,
So Then What Ive Done Is Created a Mail Merge Macro, That Opens a Word
Document And it Pulls All The Information It Project Address, Company
Address, Enquiry Details, Etc, as Ive Shown All The Fields In The Mail
Merge Through The Links from different tables,

Which then i can scroll through all the Enquiry letters on each
pages,

Which then After i Close the Mail Merge and printed my letters off the
same macro askes me if i want up date the Enquiry Records. If Click
Yes, it Automaticly Puts a Sent Date is a Sent Field in the Enquiry
Table, So there for the MailMerge Query will never pick that enquiry
up again as the sent date criteria in the query is set to Is Null (I
Created an Update Query to do this)

All This Works Perfectly,

So What I decided to do was, before The System Asks me to update the
MailMerge Quiry I Created a Report, Which Is One Page, and all is
Needed on The Report is [Project Title] and The [ProjectQNo] Also I
Have The [Enquiry No] This Is Drawing Issue Sheet, To go With The
Letters,

As The Report Source is the Mail Merge i could if i Wanted Have all
the Other Fields In there, But Not Needed,

Then I Put a SubReport In and This has [Drawings No] and [Enquiry No]
fields and The Master and Child Links are Set to [Enquiry No] Works
Like My Subform for my Enquiry,and When i Preview My Report, The
Report Has The Correct [Project QNo] the Correct [Project Title] and
The Correct [Enquiry No] In main Form, and In Sub Report It allso has
the correct Drawings Listed For That Enquiry. With The Same [Enquiry
No]

and this works, perfectly fine If I ONLY Id Assigned One Enquiry To
and Company ID. But some Time i go out to several Companys So Its
Reproducing the Drawings again, Can i Just Set the Sub Report to Just
Show The One Lot of Records?
 
D

dan.cawthorne

How do companies fit into the report? In the main report or
in the subreport?
Is there any grouping in either report?
At this point, all I can do is guess that the recotd source
query for one of the reports contains a inappropriate Join.

Well The Main Report Source Is a Query, The Same Query That Used to
Create My Mail Merge. Records Only Appear In The Mail merge Query,
Once An Enquiry is Created Note On Enquiry Form i have a continuous
Subform which i can assign Drawings To the Enquiry, The Link Field On
The Main Form and Subform is [Enquiry No] and also have a [ProjectQNo]
look Combo on the Form that I can Select a Project then i pop along to
a company form, go to a 3rd tab which has a subform on it, The Subform
is Related to a Table Called Enquiry Link, Which has 2 Primary Keys,
[ProjectQno] and [Enquiry No] Plus Specific Information Date Received,
Quote Used. Etc, Which the table enable me to have mutiply Enquirys
Per Project, or Same Enquiry and Company But Different Project.

When I Select the [Enquiry No] From the Dropdown On The Enquiry Link
Form, its assigns that Enquiry No To The Company ID

Once thats Then Assigned The Record will Show Up in The MailMerge
Query.

Which i could have 4 Records In That Query Which are all The Same
Enquiry The Only This Is Different is The Company ID, on Each Record,
So Then What Ive Done Is Created a Mail Merge Macro, That Opens a Word
Document And it Pulls All The Information It Project Address, Company
Address, Enquiry Details, Etc, as Ive Shown All The Fields In The Mail
Merge Through The Links from different tables,

Which then i can scroll through all the Enquiry letters on each
pages,

Which then After i Close the Mail Merge and printed my letters off the
same macro askes me if i want up date the Enquiry Records. If Click
Yes, it Automaticly Puts a Sent Date is a Sent Field in the Enquiry
Table, So there for the MailMerge Query will never pick that enquiry
up again as the sent date criteria in the query is set to Is Null (I
Created an Update Query to do this)

All This Works Perfectly,

So What I decided to do was, before The System Asks me to update the
MailMerge Quiry I Created a Report, Which Is One Page, and all is
Needed on The Report is [Project Title] and The [ProjectQNo] Also I
Have The [Enquiry No] This Is Drawing Issue Sheet, To go With The
Letters,

As The Report Source is the Mail Merge i could if i Wanted Have all
the Other Fields In there, But Not Needed,

Then I Put a SubReport In and This has [Drawings No] and [Enquiry No]
fields and The Master and Child Links are Set to [Enquiry No] Works
Like My Subform for my Enquiry,and When i Preview My Report, The
Report Has The Correct [Project QNo] the Correct [Project Title] and
The Correct [Enquiry No] In main Form, and In Sub Report It allso has
the correct Drawings Listed For That Enquiry. With The Same [Enquiry
No]

and this works, perfectly fine If I ONLY Id Assigned One Enquiry To
and Company ID. But some Time i go out to several Companys So Its
Reproducing the Drawings again, Can i Just Set the Sub Report to Just
Show The One Lot of Records?

also to let you know if add the drawing field to the mailmerge query
from link drawing link table then view query it create the record
several time depending how many drawings ive selected for that enquiry
so if i have 5 drawing for enquiry No 50, I get The Company Id
Repeated 5 times with a each record showing a different drawing, so
that means for Readers Ventilation lettres showing each drawing.
 
M

Marshall Barton

Well The Main Report Source Is a Query, The Same Query That Used to
Create My Mail Merge. Records Only Appear In The Mail merge Query,
Once An Enquiry is Created Note On Enquiry Form i have a continuous
Subform which i can assign Drawings To the Enquiry, The Link Field On
The Main Form and Subform is [Enquiry No] and also have a [ProjectQNo]
look Combo on the Form that I can Select a Project then i pop along to
a company form, go to a 3rd tab which has a subform on it, The Subform
is Related to a Table Called Enquiry Link, Which has 2 Primary Keys,
[ProjectQno] and [Enquiry No] Plus Specific Information Date Received,
Quote Used. Etc, Which the table enable me to have mutiply Enquirys
Per Project, or Same Enquiry and Company But Different Project.

When I Select the [Enquiry No] From the Dropdown On The Enquiry Link
Form, its assigns that Enquiry No To The Company ID

Once thats Then Assigned The Record will Show Up in The MailMerge
Query.

Which i could have 4 Records In That Query Which are all The Same
Enquiry The Only This Is Different is The Company ID, on Each Record,
So Then What Ive Done Is Created a Mail Merge Macro, That Opens a Word
Document And it Pulls All The Information It Project Address, Company
Address, Enquiry Details, Etc, as Ive Shown All The Fields In The Mail
Merge Through The Links from different tables,

Which then i can scroll through all the Enquiry letters on each
pages,

Which then After i Close the Mail Merge and printed my letters off the
same macro askes me if i want up date the Enquiry Records. If Click
Yes, it Automaticly Puts a Sent Date is a Sent Field in the Enquiry
Table, So there for the MailMerge Query will never pick that enquiry
up again as the sent date criteria in the query is set to Is Null (I
Created an Update Query to do this)

All This Works Perfectly,

So What I decided to do was, before The System Asks me to update the
MailMerge Quiry I Created a Report, Which Is One Page, and all is
Needed on The Report is [Project Title] and The [ProjectQNo] Also I
Have The [Enquiry No] This Is Drawing Issue Sheet, To go With The
Letters,

As The Report Source is the Mail Merge i could if i Wanted Have all
the Other Fields In there, But Not Needed,

Then I Put a SubReport In and This has [Drawings No] and [Enquiry No]
fields and The Master and Child Links are Set to [Enquiry No] Works
Like My Subform for my Enquiry,and When i Preview My Report, The
Report Has The Correct [Project QNo] the Correct [Project Title] and
The Correct [Enquiry No] In main Form, and In Sub Report It allso has
the correct Drawings Listed For That Enquiry. With The Same [Enquiry
No]

and this works, perfectly fine If I ONLY Id Assigned One Enquiry To
and Company ID. But some Time i go out to several Companys So Its
Reproducing the Drawings again, Can i Just Set the Sub Report to Just
Show The One Lot of Records?


It sounds like you need to filter the subreport's query to
the single company you want in the subreport. I think(?)
all you need is to use a new query based on the mail query
and add a criteria to the customer field.
 
D

dan.cawthorne

Well The Main Report Source Is a Query, The Same Query That Used to
Create My Mail Merge. Records Only Appear In The Mail merge Query,
Once An Enquiry is Created Note On Enquiry Form i have a continuous
Subform which i can assign Drawings To the Enquiry, The Link Field On
The Main Form and Subform is [Enquiry No] and also have a [ProjectQNo]
look Combo on the Form that I can Select a Project then i pop along to
a company form, go to a 3rd tab which has a subform on it, The Subform
is Related to a Table Called Enquiry Link, Which has 2 Primary Keys,
[ProjectQno] and [Enquiry No] Plus Specific Information Date Received,
Quote Used. Etc, Which the table enable me to have mutiply Enquirys
Per Project, or Same Enquiry and Company But Different Project.
When I Select the [Enquiry No] From the Dropdown On The Enquiry Link
Form, its assigns that Enquiry No To The Company ID
Once thats Then Assigned The Record will Show Up in The MailMerge
Query.
Which i could have 4 Records In That Query Which are all The Same
Enquiry The Only This Is Different is The Company ID, on Each Record,
So Then What Ive Done Is Created a Mail Merge Macro, That Opens a Word
Document And it Pulls All The Information It Project Address, Company
Address, Enquiry Details, Etc, as Ive Shown All The Fields In The Mail
Merge Through The Links from different tables,
Which then i can scroll through all the Enquiry letters on each
pages,
Which then After i Close the Mail Merge and printed my letters off the
same macro askes me if i want up date the Enquiry Records. If Click
Yes, it Automaticly Puts a Sent Date is a Sent Field in the Enquiry
Table, So there for the MailMerge Query will never pick that enquiry
up again as the sent date criteria in the query is set to Is Null (I
Created an Update Query to do this)
All This Works Perfectly,
So What I decided to do was, before The System Asks me to update the
MailMerge Quiry I Created a Report, Which Is One Page, and all is
Needed on The Report is [Project Title] and The [ProjectQNo] Also I
Have The [Enquiry No] This Is Drawing Issue Sheet, To go With The
Letters,
As The Report Source is the Mail Merge i could if i Wanted Have all
the Other Fields In there, But Not Needed,
Then I Put a SubReport In and This has [Drawings No] and [Enquiry No]
fields and The Master and Child Links are Set to [Enquiry No] Works
Like My Subform for my Enquiry,and When i Preview My Report, The
Report Has The Correct [Project QNo] the Correct [Project Title] and
The Correct [Enquiry No] In main Form, and In Sub Report It allso has
the correct Drawings Listed For That Enquiry. With The Same [Enquiry
No]
and this works, perfectly fine If I ONLY Id Assigned One Enquiry To
and Company ID. But some Time i go out to several Companys So Its
Reproducing the Drawings again, Can i Just Set the Sub Report to Just
Show The One Lot of Records?

It sounds like you need to filter the subreport's query to
the single company you want in the subreport. I think(?)
all you need is to use a new query based on the mail query
and add a criteria to the customer field.

what sort of criteria would i use?
 
M

Marshall Barton

Well The Main Report Source Is a Query, The Same Query That Used to
Create My Mail Merge. Records Only Appear In The Mail merge Query,
Once An Enquiry is Created Note On Enquiry Form i have a continuous
Subform which i can assign Drawings To the Enquiry, The Link Field On
The Main Form and Subform is [Enquiry No] and also have a [ProjectQNo]
look Combo on the Form that I can Select a Project then i pop along to
a company form, go to a 3rd tab which has a subform on it, The Subform
is Related to a Table Called Enquiry Link, Which has 2 Primary Keys,
[ProjectQno] and [Enquiry No] Plus Specific Information Date Received,
Quote Used. Etc, Which the table enable me to have mutiply Enquirys
Per Project, or Same Enquiry and Company But Different Project.
When I Select the [Enquiry No] From the Dropdown On The Enquiry Link
Form, its assigns that Enquiry No To The Company ID
Once thats Then Assigned The Record will Show Up in The MailMerge
Query.
Which i could have 4 Records In That Query Which are all The Same
Enquiry The Only This Is Different is The Company ID, on Each Record,
So Then What Ive Done Is Created a Mail Merge Macro, That Opens a Word
Document And it Pulls All The Information It Project Address, Company
Address, Enquiry Details, Etc, as Ive Shown All The Fields In The Mail
Merge Through The Links from different tables,
Which then i can scroll through all the Enquiry letters on each
pages,
Which then After i Close the Mail Merge and printed my letters off the
same macro askes me if i want up date the Enquiry Records. If Click
Yes, it Automaticly Puts a Sent Date is a Sent Field in the Enquiry
Table, So there for the MailMerge Query will never pick that enquiry
up again as the sent date criteria in the query is set to Is Null (I
Created an Update Query to do this)
All This Works Perfectly,
So What I decided to do was, before The System Asks me to update the
MailMerge Quiry I Created a Report, Which Is One Page, and all is
Needed on The Report is [Project Title] and The [ProjectQNo] Also I
Have The [Enquiry No] This Is Drawing Issue Sheet, To go With The
Letters,
As The Report Source is the Mail Merge i could if i Wanted Have all
the Other Fields In there, But Not Needed,
Then I Put a SubReport In and This has [Drawings No] and [Enquiry No]
fields and The Master and Child Links are Set to [Enquiry No] Works
Like My Subform for my Enquiry,and When i Preview My Report, The
Report Has The Correct [Project QNo] the Correct [Project Title] and
The Correct [Enquiry No] In main Form, and In Sub Report It allso has
the correct Drawings Listed For That Enquiry. With The Same [Enquiry
No]
and this works, perfectly fine If I ONLY Id Assigned One Enquiry To
and Company ID. But some Time i go out to several Companys So Its
Reproducing the Drawings again, Can i Just Set the Sub Report to Just
Show The One Lot of Records?

It sounds like you need to filter the subreport's query to
the single company you want in the subreport. I think(?)
all you need is to use a new query based on the mail query
and add a criteria to the customer field.

what sort of criteria would i use?


The same criteria you used for the main report.

Maybe I have misunderstood what you are trying to describe
and you do not want the company information to affect the
report/subreport. This can be done by only selecting the
data fields you need in the report and setting the query's
Unique Records property.
 
D

dan.cawthorne

(e-mail address removed) wrote:
Well The Main Report Source Is a Query, The Same Query That Used to
Create My Mail Merge. Records Only Appear In The Mail merge Query,
Once An Enquiry is Created Note On Enquiry Form i have a continuous
Subform which i can assign Drawings To the Enquiry, The Link Field On
The Main Form and Subform is [Enquiry No] and also have a [ProjectQNo]
look Combo on the Form that I can Select a Project then i pop along to
a company form, go to a 3rd tab which has a subform on it, The Subform
is Related to a Table Called Enquiry Link, Which has 2 Primary Keys,
[ProjectQno] and [Enquiry No] Plus Specific Information Date Received,
Quote Used. Etc, Which the table enable me to have mutiply Enquirys
Per Project, or Same Enquiry and Company But Different Project.
When I Select the [Enquiry No] From the Dropdown On The Enquiry Link
Form, its assigns that Enquiry No To The Company ID
Once thats Then Assigned The Record will Show Up in The MailMerge
Query.
Which i could have 4 Records In That Query Which are all The Same
Enquiry The Only This Is Different is The Company ID, on Each Record,
So Then What Ive Done Is Created a Mail Merge Macro, That Opens a Word
Document And it Pulls All The Information It Project Address, Company
Address, Enquiry Details, Etc, as Ive Shown All The Fields In The Mail
Merge Through The Links from different tables,
Which then i can scroll through all the Enquiry letters on each
pages,
Which then After i Close the Mail Merge and printed my letters off the
same macro askes me if i want up date the Enquiry Records. If Click
Yes, it Automaticly Puts a Sent Date is a Sent Field in the Enquiry
Table, So there for the MailMerge Query will never pick that enquiry
up again as the sent date criteria in the query is set to Is Null (I
Created an Update Query to do this)
All This Works Perfectly,
So What I decided to do was, before The System Asks me to update the
MailMerge Quiry I Created a Report, Which Is One Page, and all is
Needed on The Report is [Project Title] and The [ProjectQNo] Also I
Have The [Enquiry No] This Is Drawing Issue Sheet, To go With The
Letters,
As The Report Source is the Mail Merge i could if i Wanted Have all
the Other Fields In there, But Not Needed,
Then I Put a SubReport In and This has [Drawings No] and [Enquiry No]
fields and The Master and Child Links are Set to [Enquiry No] Works
Like My Subform for my Enquiry,and When i Preview My Report, The
Report Has The Correct [Project QNo] the Correct [Project Title] and
The Correct [Enquiry No] In main Form, and In Sub Report It allso has
the correct Drawings Listed For That Enquiry. With The Same [Enquiry
No]
and this works, perfectly fine If I ONLY Id Assigned One Enquiry To
and Company ID. But some Time i go out to several Companys So Its
Reproducing the Drawings again, Can i Just Set the Sub Report to Just
Show The One Lot of Records?
It sounds like you need to filter the subreport's query to
the single company you want in the subreport. I think(?)
all you need is to use a new query based on the mail query
and add a criteria to the customer field.
what sort of criteria would i use?

The same criteria you used for the main report.

Maybe I have misunderstood what you are trying to describe
and you do not want the company information to affect the
report/subreport. This can be done by only selecting the
data fields you need in the report and setting the query's
Unique Records property.

Well Thank You for The Advise, But ive Just Managed to Sort it,

All I Did Was Move The Sub/Report From The Detail Section, and Moved
into The Page Title Section Where The [Project QNo], [Project Title]
and [Enquiry Item] Fields are and its Done what i wanted. Don't Know
Why,Or How Just That it Has.

Would You Know How I Could Filter My Combo List Box [Drawings No]
Which is in My Subform, Where When I Selected the The Project From The
[Project QNo] Field (Combo Box as well) On Main Form where the Subform
is, The [Drawing No] Combo Only Shows Those Related Drawings To That
Project?

I Did Try An After Event on the [Project QNo] But the Following SQL
But NoLuck, "SELECT Drawings.[ProjectQNo], Drawings.
[Drawing Number] FROM Drawings WHERE Drawings.[ProjectQNo] = """ & me!
[cboProject QNo] & """""" But I Get folloWhen I Select A Project i
Get The Following Dailog Message.

The Expression After Update You entered as the event Property Setting
Produced the following error: The Object Doesnt Contain The Automation
Object "Me." wing Dialog Message
 
M

Marshall Barton

Well Thank You for The Advise, But ive Just Managed to Sort it,

All I Did Was Move The Sub/Report From The Detail Section, and Moved
into The Page Title Section Where The [Project QNo], [Project Title]
and [Enquiry Item] Fields are and its Done what i wanted. Don't Know
Why,Or How Just That it Has.

Would You Know How I Could Filter My Combo List Box [Drawings No]
Which is in My Subform, Where When I Selected the The Project From The
[Project QNo] Field (Combo Box as well) On Main Form where the Subform
is, The [Drawing No] Combo Only Shows Those Related Drawings To That
Project?

I Did Try An After Event on the [Project QNo] But the Following SQL
But NoLuck, "SELECT Drawings.[ProjectQNo], Drawings.
[Drawing Number] FROM Drawings WHERE Drawings.[ProjectQNo] = """ & me!
[cboProject QNo] & """""" But I Get folloWhen I Select A Project i
Get The Following Dailog Message.

The Expression After Update You entered as the event Property Setting
Produced the following error: The Object Doesnt Contain The Automation
Object "Me." wing Dialog Message


Even though I still don't know enough about your situation
to evaluate what you've done, it is good to hear that you
now have it working.

Your new question about the combo box is also unclear. What
is the code in the Project QNo combo box's AfterUpdate event
procedure? Is that SQL statement in the combo box's
RowSource property or in the AfterUpdate procedure? Either
way the quotes are wrong.

If it is in the Project QNo AfterUpdate procedure, then it
should be more like:

Me.subformcontrol.Form.[Drawings No].RowSource = _
"SELECT ProjectQNo, [Drawing Number] " & _
"FROM Drawings " & _
"WHERE ProjectQNo = """ & Me![cboProject QNo] & """"

but that assumes the ProjectQNo field is a Text field (in
its table).

If the ProjectQNo field (in its table) is a number type,
then the code would be:

Me.subformcontrol.Form.[Drawings No].RowSource = _
"SELECT ProjectQNo, [Drawing Number] " & _
"FROM Drawings " & _
"WHERE ProjectQNo = " & Me![cboProject QNo]
 
D

dan.cawthorne

Well Thank You for The Advise, But ive Just Managed to Sort it,
All I Did Was Move The Sub/Report From The Detail Section, and Moved
into The Page Title Section Where The [Project QNo], [Project Title]
and [Enquiry Item] Fields are and its Done what i wanted. Don't Know
Why,Or How Just That it Has.
Would You Know How I Could Filter My Combo List Box [Drawings No]
Which is in My Subform, Where When I Selected the The Project From The
[Project QNo] Field (Combo Box as well) On Main Form where the Subform
is, The [Drawing No] Combo Only Shows Those Related Drawings To That
Project?
I Did Try An After Event on the [Project QNo] But the Following SQL
But NoLuck, "SELECT Drawings.[ProjectQNo], Drawings.
[Drawing Number] FROM Drawings WHERE Drawings.[ProjectQNo] = """ & me!
[cboProject QNo] & """""" But I Get folloWhen I Select A Project i
Get The Following Dailog Message.
The Expression After Update You entered as the event Property Setting
Produced the following error: The Object Doesnt Contain The Automation
Object "Me." wing Dialog Message

Even though I still don't know enough about your situation
to evaluate what you've done, it is good to hear that you
now have it working.

Your new question about the combo box is also unclear. What
is the code in the Project QNo combo box's AfterUpdate event
procedure? Is that SQL statement in the combo box's
RowSource property or in the AfterUpdate procedure? Either
way the quotes are wrong.

If it is in the Project QNo AfterUpdate procedure, then it
should be more like:

Me.subformcontrol.Form.[Drawings No].RowSource = _
"SELECT ProjectQNo, [Drawing Number] " & _
"FROM Drawings " & _
"WHERE ProjectQNo = """ & Me![cboProject QNo] & """"

but that assumes the ProjectQNo field is a Text field (in
its table).

If the ProjectQNo field (in its table) is a number type,
then the code would be:

Me.subformcontrol.Form.[Drawings No].RowSource = _
"SELECT ProjectQNo, [Drawing Number] " & _
"FROM Drawings " & _
"WHERE ProjectQNo = " & Me![cboProject QNo]

--
Marsh
MVP [MS Access]- Hide quoted text -

- Show quoted text -

Thanks For Getting Back Intouch, Was The Google Groups Playing The
Other Day?
Well Thanks For The Information It Helped. Have a Good Weekend Dan
 

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

Top