Microsoft VBScript runtime (0x800A0009)
Subscript out of range: '[number: 0]'
code ทั้งหมด .asp
<%Option Explicit%>
<html>
<head>
<title>Import_summay_dcn .CSV To Access</title>
</head>
<body>
<%
Dim objFSO,oInStream,sRows,arrRows
Dim Conn,strSQL,objExec
Dim sFileName
sFileName = "tl_summary_dcn.csv"
'*** Create Object ***'
Set objFSO = CreateObject("Scripting.FileSystemObject")
'*** Check Exist Files ***'
If Not objFSO.FileExists(Server.MapPath(sFileName)) Then
Response.write("File not found.")
Else
'*** Open Files ***'
Set oInStream = objFSO.OpenTextFile(Server.MapPath(sFileName),1,False)
'*** open Connect to Access Database ***'
Set Conn = Server.Createobject("ADODB.Connection")
Conn.Open "DRIVER=Microsoft Access Driver (*.mdb);DBQ=" & Server.MapPath("/datadcn/dcn.mdb"),"" , ""