A1VBCode Forums

confused on how to use open args


http://www.a1vbcode.com/vbforums/Topic32161.aspx

By cuddles - 6/7/2014

I have a form with listboxes. The end-user selects what they want and then can click a button to show their results in a continuous form. Because there are many listboxes and the continuous form is just too busy, I created another button for the user to select when they want to get to another form that has a subform pivot chart. When they click the button, it is supposed to take the filter and feed it to the form and subform pivot chart. If I create the following code:





Private Sub cmdResults_Click()

DoCmd.OpenForm "frmSearch", acNormal,, GetFilter

DoCmd.OpenForm "frmGraph", acFormPivotChart,, GetFilters

End Sub





Both forms are update properly and both open in their own tab. The issue is, I embedded the pivotchart into the frmSearch and the frmSearch shows the results correctly but the pivotchart does not update. Now, this does not have to be forms. I can do a report called rptSearch and then embed the form frmGraph. Does not matter. Just not sure how to code the open args to apply the filter........GetFilter to each item but have it do it when the item is embedded.