Professional Documents
Culture Documents
Student’s Signature:
Manoj Sharma.
Reg. No., Student Name class, Marks in three subjects. This data should
Program should fetch data from table(s), display all the above information &
ANS 1.
<html>
<body>
<%
Set conn1=server.createobject(“ADODB.Connection”)
Conn1.provider=”Microsoft.Jet.OLEDB.4.0”
CONN1.OPEN=”C:\MARKS.ASP”
Server.rst=server.createobject(“ADODB.Recordset”)
%>
<%
Conn.execute sq
%>
<table>
<tr>
<td><%response. Write(x.value)%></td>
<%next>
</tr>
<%loop>
</table>
</body>
</html>
Q2. Write a program using ASP to read and write binary data into a file which
Ans:
Following is the ASP code of how to read and write binary data into a file:
'Open the stream And get binary data from the object
ReadBinaryFile = BinaryStream.Read
End Function
ANS 3.
<HTML>
<body>
<%
Set conn1=server.createobject(“ADODB.Connection”)
Conn1.provider=”Microsoft.Jet.OLEDB.4.0”
CONN1.OPEN=”C:\REGISTRATIONFORM.ASP”
Server.rst=server.createobject(“ADODB.Recordset”)
%>
<%
Conn.execute sq
%>
<table>
<tr>
<%next>
</tr>
<%loop>
</table>
</body>
</html>
Part-B
table by taking values from user using textboxes, Radio buttons etc.
Program should fetch data from table(s), display all the above information &
ANS 4.
<HTML>
<body>
<%
Set conn1=server.createobject(“ADODB.Connection”)
Conn1.provider=”Microsoft.Jet.OLEDB.4.0”
CONN1.OPEN=”C:\EMPLOYEE DETAIL.ASP”
Server.rst=server.createobject(“ADODB.Recordset”)
%>
<%
Conn.execute sq
%>
<table>
<tr>
<%next>
</tr>
<%loop>
</table>
</body>
</html>
Q5. Create a web application in ASP to perform insertion, deletion & updating
RECORDS IN ASP:
<%
%>
<%
SetCommand1=Server.CreateObject("ADODB.Command")
Command1.ActiveConnection=MM_YourConnection_STRING
Replace(Command1__var2, "'", "''") + "', " + Replace(Command1__var3," ' " ," ''
Command1.CommandType=1
Command1.CommandTimeout=0
Command1.Prepared=true
Command1.Execute()
%>
Q6. Create a web application that can be used by a bank to help it in making
ANS: 6.
<html>
<body>
<%
Set conn1=server.createobject(“ADODB.Connection”)
Conn1.provider=”Microsoft.Jet.OLEDB.4.0”
CONN1.OPEN=”C:\BANKFORM.ASP”
Server.rst=server.createobject(“ADODB.Recordset”)
%>
<%
Conn.execute sq
%>
<table>
<tr>
<td><%response. Write(x.value)%></td>
<%next>
</tr>
<%loop>
</table>
</body>
</html>