Trying to use a form tab control's page name as a query criteria

  • Thread starter Thread starter ragtopcaddy via AccessMonster.com
  • Start date Start date
R

ragtopcaddy via AccessMonster.com

Here's the criteria:

Forms!frmStoreMaster.tabYears.pages(Forms!frmStoreMaster.tabYears).name

When I put it in the immediate window with a question mark, it returns "2004".


When I try to use it as criteria for the year field in a query, I get "The
expression you entered has an invalid . (dot)...", and the dot before "name"
at the end of the string is highlighted.

Please advise.

--
Bill Reed

"If you can't laugh at yourself, laugh at somebody else"

Message posted via AccessMonster.com
 
Not a bad idea!

I was hoping there was some syntax I could use in the criteria that would
relieve me of that necessity. Oh well, it was a nice try.

Thanks,



Alex said:
Hi,
I think best if you would make a new function, which returns
Forms!frmStoreMaster.tabYears.pages(Forms!frmStoreMaster.tabYears).name and
use it in a query
Here's the criteria:
[quoted text clipped - 9 lines]
Please advise.

--
Bill Reed

"If you can't laugh at yourself, laugh at somebody else"

Message posted via AccessMonster.com
 
Back
Top