Wrox Programmer Forums
|
Classic ASP Components Discussions specific to components in ASP 3.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Components section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 23rd, 2003, 03:39 PM
boo boo is offline
Registered User
 
Join Date: Jul 2003
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default searge page...

I must key in FirstName, LastName and IcNo to searching, and it will display the data from member, how to do it? Can u please modify my coding? It display nothing and why display the admin MemberId? Pls show me clearer..
My coding showing below:



<%
'open the database connection
Set con=Server.CreateObject("ADODB.Connection")
'con.open "Provider=SQLOLEDB.1; Password=; UserID=BOO; Initial Catalog=dta; Data Source=webserver;"
con.open "DSN=dta"

Set rs=Server.CreateObject("ADODB.Recordset")
rs.CursorType=adOpenStatic
rs.CursorLocation=adUseServer
rs.LockType=adLockBatchOptimistic

if trim(request.form("FirstName"))<> " " and _
   trim(request.form("LastName"))<> " " and _
   trim(request.form("IcNo"))<> " " then

sql= "Select * from Member where FirstName=' " &_
    trim(request.form("SFirstName")) &_
    "' and LastName='" & trim(request.form("SLastName")) &_
    "' and IcNo='" & trim(request.form("SIcNo")) & "'"
else
    response.redirect "Error_no_record.asp"
end if

con.close
set con=nothing
set rs=nothing
%>







Similar Threads
Thread Thread Starter Forum Replies Last Post
how to prevent a web page/window page from copying pradeeppatnaik81 C# 2 April 9th, 2008 03:36 AM
access C#.Net page as action of calssic ASP page mansharma_s ASP.NET 1.x and 2.0 Application Design 6 January 7th, 2008 10:58 AM
How to pass the variables in Aspx page to Asp Page jayaraj ASP.NET 1.0 and 1.1 Basics 3 May 23rd, 2004 06:55 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.