|
Question : Subform Problems, Method Form of object Subform failed
|
|
I have a form (frmMetrics) with a single subform (subform1) which has a source object is (sfrmMetrics). On the main form I have a list box (listNames). With the AfterUpdate event of listNames, I want to change the RecordSource of subform1. Please nobody send me http://www.mvps.org/access/forms/frm0031.htm as I have that reference already. Must not be reading it right or something though, because I keep getting Method Form of object Subform failed.
This is what I have now: Private Sub listNames_AfterUpdate() Me.subform1.Form.RecordSource = "qryMetricsSrtd" End Sub I also tried Me!subform1.Form.RecordSource and Me!subform!.form!recordsource. I tried putting the query SQL into a string and feeding it that instead. I also tried Me.subform1.Form.Filter = .... and that bombed, same error. However, I am able to change the SourceObject no problem (me.subform1.sourceobject = ...) Thinking it could be a problem with Me (no pun intended) I also tried Forms!frmMetrics.subform1.Form.RecordSource = "qryMetricsSrtd" with the same error.
|
|
Answer : Subform Problems, Method Form of object Subform failed
|
|
PAQed with points refunded (250)
Computer101 EE Admin
|
|
|
|