I'm thinking maybe the querystring is getting interpreted as a string? Try this: qsmonth=CInt(request.querystring("rqmonth")) Hope this helps.