<%@ Language=VBScript %>
<!--#include file="includes/adovbs.inc"-->
<%
vXlsFile = "virtual/documents/TechReport/GetIP21Data.xlsm"
vXlsFile = Server.Mappath(vXlsFile)
ExcelConnString = "Provider=Microsoft.ACE.OLEDB.12.0;" & _
"Data Source=" & chr(34) & vXlsFile & chr(34) & ";" & _
"Extended Properties=" & chr(34) & "Excel 12.0 Xml;HDR=YES;"& chr(34)
'Open Database Connection
Set Conn = Server.CreateObject("ADODB.Connection")
Conn.Open ExcelConnString
%>
<html>
<head>
</head>
<body>
<%
Sql = "SELECT * FROM tblData;"
set RS = server.createobject("adodb.recordset")
RS.open sql,Conn,adOpenForwardOnly,adLockReadOnly
if rs.bof and rs.eof then
response.write "<br>No Records Returned!"
else
Rs.Movefirst
%>
<table width="100%" border="1" cellpadding="0" cellspacing="0" class="stats-table">
<tr>
<th id="dailyInclude" style="width: 289px"> </th>
<th id="monthCOL" style="width: 244px">Tag</th>
<th id="YTDCOL" style="width: 359px">Value</th>
</tr>
<%
do while not rs.eof
%>
<tr>
<td class="rowType" style="width: 289px">Freeport</td>
<td align="center" style="width: 244px"><%=RS.Fields("TagName")%></td>
<td align="center" style="width: 359px"><%=RS.Fields("InputValue")%></td>
<%
rs.movenext
loop
rs.close
set rs = nothing
%>
<%
end if
Conn.Close
set conn = nothing
%>
</tr>
</table>
</body>
</html>
my issue is that I will not have that named range called tblData to use like a data table so dont know how to handle pulling the data in.
<table>
<tr><td>Name</td><td>Email</td><td>Phone</td></tr>
<%
line="mike, mike@someplace.com, 1111111111"
arrLine=split(line,",")
Name=arrLine(0)
Email=arrLine(1)
Phone=arrLine(2)
%>
<tr><td><%=Name%></td><td><%=Email%></td><td><%=Phone%></td></tr>
</table>