Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

object type argument blank or invlaid

Status
Not open for further replies.

BigMrC

Technical User
Nov 4, 2003
21
NZ
I have a macro run from an autokey (F12) that uses SendTo to send the current report that's on screen to an email as an attachment. This has been working perfectly for years and all of a sudden when I hit the F12 key I get:
The Object Type argument for the action or method is blank or invalid.
It's fine to just right click the report and use Send To but this is a pain for my users who just want to hit F12 as before.

Anybody help?

Thanks
 
Check your AutoKey macro.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
Autokey macro is fine, I have other databases where the F12 auto email thing still works fine, only a couple of my databases where this has started happening - and they're no different to the others.
 
only a couple of my databases
On same mchine, same OS (version and SP), same access (version and SP), same msoffice (version and SP) ?

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
damn found the cause of it!
Seemed that it was only doing it for some reports and not others.
All the reports I run are run from a command button and they all have a me.refresh followed by the command to open the report.
When I removed the me.refresh from the ones that wouldn't F12 / SendTo they started working!
Problem is I need a me.refresh prior to running these reports as any new data just entered on the screen needs to be refreshed/saved so the report will pick it up.
So questions now are:

1. why would a me.refresh on a command button used to open a report cause a SendTo error message, and only with some reports not others.

2. what can I use instead of me.refresh to save any just-entered data so it will appear on the report being run.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top