ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Parameter query conversion error on date (https://www.excelbanter.com/excel-discussion-misc-queries/209548-parameter-query-conversion-error-date.html)

SusanJane sjl

Parameter query conversion error on date
 
I have a pivot table that uses a MS Query to retrieve data. I have the
StatusDate criteria value as =[Begin Date]. When the popup comes up asking
for the date, I enter in 9/1/08 or 9/1/2008 or 9-1-08 or and I get an msg
"Conversion Error". If I key into the criteria value =9/1/08 it works just
fine. BUT I need to use a parameter so the user doesn't have to edit the
query every time it's run.
--
Always grateful for help!!

ShaneDevenshire

Parameter query conversion error on date
 
Hi,

A little more info, the parameter box that is popping up - is that
controlled by VBA or is the handled by MS query? If via VBA could you post
the code. If it is done directly in MS query how? via the SQL statement or
....

If it is being handled in MS Query you will need to switch to using VBA to
run the query so you can convert the users input into an acceptable format.
Alternatively you can teach the user the acceptable way to enter the dates.
--
Thanks,
Shane Devenshire


"SusanJane sjl" wrote:

I have a pivot table that uses a MS Query to retrieve data. I have the
StatusDate criteria value as =[Begin Date]. When the popup comes up asking
for the date, I enter in 9/1/08 or 9/1/2008 or 9-1-08 or and I get an msg
"Conversion Error". If I key into the criteria value =9/1/08 it works just
fine. BUT I need to use a parameter so the user doesn't have to edit the
query every time it's run.
--
Always grateful for help!!



All times are GMT +1. The time now is 10:23 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com