I assume you use VBScript. Do you declare that at the top of your second page?, like so: <%@ Language=VBScript %>