"Enter parameter value" error when exporting to Excel (but not if to other formats)
"Enter parameter value" error when exporting to Excel (but not if to other formats)
am 31.10.2007 12:43:36 von myemail.an
Hi all,
I use Access 2007 and have come across this error a number of times.
I have two tables (customer information) which should contain -
ideally - the same data.
I create a query to compare them based on customer code. The fields
are something like:
Customer code
Balance - Table 1
Balance - Table 2
Difference (the difference of the 2 fields above)
and so on.
The query runs fine, so I guess there is no error in the expressions.
However, if I try to export to Excel, I get the message "Enter
parameter value", as though Access did not understand one of the
values in the expressions; however, the query did run fine. Also, if I
export to csv, I don't get this message.
Any idea? I am an Access novice, but this really makes no sense to me :
(
Re: "Enter parameter value" error when exporting to Excel (but not if to other formats)
am 31.10.2007 12:56:17 von Allen Browne
When Access pops up the dialog asking you for the parameter, what is the
name it asks you for?
It may help if you post the SQL statement for the query too.
--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.
wrote in message
news:1193831016.543690.40800@22g2000hsm.googlegroups.com...
> Hi all,
>
> I use Access 2007 and have come across this error a number of times.
> I have two tables (customer information) which should contain -
> ideally - the same data.
> I create a query to compare them based on customer code. The fields
> are something like:
> Customer code
> Balance - Table 1
> Balance - Table 2
> Difference (the difference of the 2 fields above)
> and so on.
>
> The query runs fine, so I guess there is no error in the expressions.
> However, if I try to export to Excel, I get the message "Enter
> parameter value", as though Access did not understand one of the
> values in the expressions; however, the query did run fine. Also, if I
> export to csv, I don't get this message.
>
> Any idea? I am an Access novice, but this really makes no sense to me
Re: "Enter parameter value" error when exporting to Excel (but not if to other formats)
am 31.10.2007 13:14:40 von myemail.an
On 31 Oct, 11:56, "Allen Browne" wrote:
> When Access pops up the dialog asking you for the parameter, what is the
> name it asks you for?
Access truncates the names in the window, so I cannot be sure. I tried
to enlarge the window, but I can't.
> It may help if you post the SQL statement for the query too.
The SQL code is very long. I'll try creating a query with fewer fields
and, if the problem persists, post the SQL code for that. Thanks!
Btw, I still don't understand why I only get this message when
exporting and not when running the query.
Re: "Enter parameter value" error when exporting to Excel (but not if to other formats)
am 31.10.2007 13:38:22 von Allen Browne
If you saved the query as Query1, you may be able to get Access to tell you
about the parameters by opening the Immediate Window (Ctrl+G) and entering
lines like this:
? Currentdb.QueryDefs("MyQuery").Parameters.Count
? Currentdb.QueryDefs("MyQuery").Parameters(0).Name
--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.
wrote in message
news:1193832880.289366.162710@k79g2000hse.googlegroups.com.. .
> On 31 Oct, 11:56, "Allen Browne" wrote:
>> When Access pops up the dialog asking you for the parameter, what is the
>> name it asks you for?
>
> Access truncates the names in the window, so I cannot be sure. I tried
> to enlarge the window, but I can't.
>
>> It may help if you post the SQL statement for the query too.
>
> The SQL code is very long. I'll try creating a query with fewer fields
> and, if the problem persists, post the SQL code for that. Thanks!
>
> Btw, I still don't understand why I only get this message when
> exporting and not when running the query.
>