Microsoft VBScript compilation (0x800A0401) Expected end of statement

I created my connection string in Dreamweaver MX as shown below:

<%
' FileName="Connection_ado_conn_string.htm"
' Type="ADO"
' DesigntimeType="ADO"
' HTTP="false"
' Catalog=""
' Schema=""
Dim MM_NCA_Con2_STRING
MM_NCA_Con2_STRING = Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Inetpub\wwwroot\SMU Cheer\fpdb\NCA_IMPORT.xls;Extended Properties="Excel 8.0;HDR=Yes;IMEX=1"";
%>

I added the second double quote after IMEX=1, as I it said to do so below the example I found on here. When I put it in the connection string dialogue..it connects sucessfully. However, when I try to test an ASP page..I get the following error:

Error Type:
Microsoft VBScript compilation (0x800A0401)
Expected end of statement
/smu cheer/Connections/NCA_Con2.asp, line 9, column 49
MM_NCA_Con2_STRING = Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Inetpub\wwwroot\SMU Cheer\fpdb\NCA_IMPORT.xls;Extended Properties="Excel 8.0;HDR=Yes;IMEX=1"";

Any help would be GREATLY appreciated!

Thank you!
Skye Brannon

1 answer

Hi Skye
You should put two double quotes at both places.. i e
Extended Properties=""Excel 8.0;HDR=Yes;IMEX=1"";
Not
Extended Properties="Excel 8.0;HDR=Yes;IMEX=1"";
as in your example.

Hope this helps!