Dim SQLStr
SQLStr = "INSERT ALL INTO TABLENAME "
for each file in filCollection
file_name = file.name
path = folderObj & "\" & file_name
Set objExcel_chk = CreateObject("Excel.Application")
Set ws1 = objExcel_chk.Workbooks.Open(path).Sheets(1)
row_cnt = 1
'for row_cnt = 6 to 7
' if ws1.Cells(row_cnt,col_cnt).Value <> "" then
' col = col_cnt
' end if
'next
While (ws1.Cells(row_cnt, 1).Value <> "")
for col_cnt = 1 to 10
SQLStr = SQLStr & "VALUES('" & ws1.Cells(row_cnt, 1).Value & "')"
next
row_cnt = row_cnt + 1
WEnd
'objExcel_chk.Quit
objExcel_chk.Workbooks.Close()
set ws1 = nothing
objExcel_chk.Quit
Response.Write(SQLStr)
'set filobj = FSYSObj.GetFile (sub_fol_path & "\" & file_name)
'filobj.Delete
next
End if
End If
i used this code to upload the excel file to the server. now i need to save it to a database. can anyone guide mehow to do that. i know my question is very subjective. sorry for that. any help is very much appriciated