General discussion

Locked

ASP showing MSAccess 97 forms

By gmoore ·
I have an employee "In/Out board" dB. I wish to call/show frmIn_Out via an ASP page. "I Know Nut-ing" about ASP. Suggestions? Please? WHat should one watch out for? What are pitfalls?

This conversation is currently closed to new comments.

3 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Comments

Collapse -

ASP showing MSAccess 97 forms

by andrew In reply to ASP showing MSAccess 97 f ...

ASP is simply a server-side scripting engine. Ultimately, ASP pages generate HTML and send it back to the browser.

You won't be able to directly use the forms in ASP. What I recommend you do, is write a simple ASP page that reads from the Access data, and generates a simple HTML page.

Here is the entire ASP page code:

<%@ Language=VBScript %>
<%Option Explicit%>
<HTML>
<HEAD>
<META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">
</HEAD>
<BODY>
<%
Dim sDSN
Dim oCon
DimoRS

on error resume next
sDSN = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\db1.mdb;"
Set oCon = Server.CreateObject("ADODB.Connection")
Set oRS = Server.CreateObject("ADODB.Recordset")

oCon.Open sDSN
oRS.Open "SELECT * FROM Table1", oCon
Do
Response.Write oRS.Fields("Name").Value & " " & oRS.Fields("Status").Value & "<br>"
oRS.MoveNext
Loop until oRS.EOF
%>

</font>
</BODY>
</HTML>

It gets a recordset, loops through it and writes an HTML line for each person and the In/Out status.

I'll email you the sample Db I used for this.

Collapse -

ASP showing MSAccess 97 forms

by gmoore In reply to ASP showing MSAccess 97 f ...

Was able to use code & response with only a little modification.

Collapse -

ASP showing MSAccess 97 forms

by gmoore In reply to ASP showing MSAccess 97 f ...

This question was closed by the author

Back to Web Development Forum
3 total posts (Page 1 of 1)  

Related Discussions

Related Forums