How to change sub form recordsource? 
Author Message
 How to change sub form recordsource?

I have a subformMailingLabel. I want to change the
subform's recordsource. Obviously, I cannot use
Me.SubformMailingLabel.RecordSource
= "qryMailingLabelByCity", How can I set it?
Thanks for your suggestion!
Best Regards
Lynda


Mon, 29 Aug 2005 02:30:57 GMT  
 How to change sub form recordsource?
You're close:

Me.SubformMailingLabel.form.RecordSource = "qryMailingLabelByCity"

Where subformMailingLabel is the name of the subform control on the mainform
(which is not necessarily the same as the name of the form object being used
in the subform).

--
Sandra Daigle
[Microsoft Access MVP]
For the benefit of others please post all replies to this newsgroup.

Quote:

> I have a subformMailingLabel. I want to change the
> subform's recordsource. Obviously, I cannot use
> Me.SubformMailingLabel.RecordSource
> = "qryMailingLabelByCity", How can I set it?
> Thanks for your suggestion!
> Best Regards
> Lynda



Mon, 29 Aug 2005 02:56:02 GMT  
 How to change sub form recordsource?
Thanks! Sandra, It works!
Best Regards
Lynda
Quote:
>-----Original Message-----
>You're close:

>Me.SubformMailingLabel.form.RecordSource

= "qryMailingLabelByCity"
Quote:

>Where subformMailingLabel is the name of the subform

control on the mainform
Quote:
>(which is not necessarily the same as the name of the

form object being used
Quote:
>in the subform).

>--
>Sandra Daigle
>[Microsoft Access MVP]
>For the benefit of others please post all replies to this
newsgroup.


>> I have a subformMailingLabel. I want to change the
>> subform's recordsource. Obviously, I cannot use
>> Me.SubformMailingLabel.RecordSource
>> = "qryMailingLabelByCity", How can I set it?
>> Thanks for your suggestion!
>> Best Regards
>> Lynda

>.



Mon, 29 Aug 2005 03:23:42 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Recordsource: Changing RecordSource on Sub Form

2. Changing Recordsource of Sub Form to Stored Query With Parameters

3. How to change sub form's recordsource?

4. Changing Recordsource of Sub Form to Stored Query With Parameters

5. Access is crashing after setting RecordSource of a form with a sub form

6. Changing Recordsource for Sub Report via vba

7. Assigning a created ado recordset to a sub forms recordsource

8. opening a sub-recordset on form's recordsource

9. Access95: chance recordsource in sub-form

10. Access95: chance recordsource in sub-form


 
Powered by phpBB® Forum Software © phpBB Group