J
JohnM77 via AccessMonster.com
I have a main form (frmMain) that loads when the database (Access 2003) is
opened. The frmMain contains a series of commandbuttons that open additional
forms using statements such as the following:
Private Sub cmdOpenSalesOrdersForm_Click()
DoCmd.OpenForm "frmSalesOrders", acNormal, , , , acDialog
End Sub
The frmSalesOrders contains a commandbutton that is supposed to Setfocus on
an embedded Subform (subTable) and then invoke the Find dialog using the
following statements:
Private Sub cmdFind_Click()
subTable.SetFocus
RunCommand acCmdFind
End Sub
When frmSalesOrders is opened using the button on the main form, the
following error is raised:
Error 2046: Command or action Find isn't available now.
If the same frmSalesOrders form is opened directly from the database window,
the Find button works perfectly. How can I make the acCmdFind command
function properly when I open frmSalesOrder from the frmMain button-click?
I tried googling for solutions, but can't find info directly related to this
issue. Any suggestions are greatly appreciated.
Thanks,
John
is opened in this manner
opened. The frmMain contains a series of commandbuttons that open additional
forms using statements such as the following:
Private Sub cmdOpenSalesOrdersForm_Click()
DoCmd.OpenForm "frmSalesOrders", acNormal, , , , acDialog
End Sub
The frmSalesOrders contains a commandbutton that is supposed to Setfocus on
an embedded Subform (subTable) and then invoke the Find dialog using the
following statements:
Private Sub cmdFind_Click()
subTable.SetFocus
RunCommand acCmdFind
End Sub
When frmSalesOrders is opened using the button on the main form, the
following error is raised:
Error 2046: Command or action Find isn't available now.
If the same frmSalesOrders form is opened directly from the database window,
the Find button works perfectly. How can I make the acCmdFind command
function properly when I open frmSalesOrder from the frmMain button-click?
I tried googling for solutions, but can't find info directly related to this
issue. Any suggestions are greatly appreciated.
Thanks,
John
is opened in this manner