|
It is currently Fri Jan 09, 2009 1:37 am
|
View unanswered posts | View active topics
|
Page 1 of 1
|
[ 1 post ] |
|
| Author |
Message |
|
knightm22
|
Post subject: Begininer, needing help with ASP numeracy - Happy Christmas Posted: Wed Dec 22, 2004 11:38 am |
|
Joined: Wed Dec 22, 2004 11:36 am Posts: 0 Location: York, UK
|
|
Hi,
I need to display in my form fields the last record in my access database, which is a numerical value, then add 1 to that value.
The code i have so far is:
<%
' Name of the Accessdb being read
accessdb="form1"
' Connect to the db with a DSN-less connection
cn="DRIVER={Microsoft Access Driver (*.mdb)};"
cn=cn & "DBQ=" & server.mappath(accessdb)
' Create a server recordset object
Set rs = Server.CreateObject("ADODB.Recordset")
rs.CursorType = 3
' Select specific fields from the table the_bird
sql = "select t1004, t6103 from doc"
' Execute the sql
rs.Open sql, cn
%>
<%
rs.movelast
%>
<%= rs("t1004") %>">
<%= rs("t6103") %>">
|
|
| Top |
|
 |
|
Page 1 of 1
|
[ 1 post ] |
|
Who is online |
Users browsing this forum: No registered users and 0 guests |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot post attachments in this forum
|
|
Welcome to DEVPPL.com
You are not logged in, which means that you can't post in the forums. Click here to Register
If you are a current member here on DEVPPL, please login below:
|
|
|