Advertisement

06.19.2008 at 04:59AM PDT, ID: 23498436
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

6.9

How can add one record to an Access datbase using an ASP form page while not changing any of the other records in the form?

Asked by kfranck in Active Server Pages (ASP), Microsoft Access Database

I created an ASP project that I need the user to update one record "Status" on the select_asp page. When the user clicks on the hypertext link, it opens another forms page and the user can add the Status (FINISHED, IN PROCESS, etc.)  No other records should be changed or have the ability to be changed. Those other records should be read-only or have another color, etc.

How can this be done? I am seeking suggestions.

I have included the forms page in the attached code snippet.


Start Free Trial
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64:
65:
66:
67:
68:
69:
70:
71:
72:
73:
74:
75:
76:
77:
78:
79:
80:
81:
82:
83:
84:
85:
86:
87:
88:
89:
90:
91:
92:
93:
94:
95:
96:
97:
98:
99:
100:
101:
102:
103:
104:
105:
106:
107:
108:
109:
110:
111:
112:
113:
114:
115:
116:
117:
118:
119:
120:
121:
122:
123:
124:
125:
126:
127:
128:
129:
130:
131:
132:
133:
134:
135:
136:
137:
138:
139:
140:
141:
142:
143:
144:
145:
146:
147:
148:
149:
150:
151:
152:
153:
154:
155:
156:
157:
158:
159:
160:
161:
162:
163:
164:
165:
166:
<%
'Dimension variables
Dim adoCon 			'Holds the Database Connection Object
Dim rsMasterRolodex		'Holds the recordset for the record to be updated
Dim strSQL			'Holds the SQL query for the database
Dim lngRecordNo			'Holds the record number to be updated
 
'Read in the record number to be updated
lngRecordNo = CLng(Request.QueryString("ID"))
 
'Create an ADO connection odject
Set adoCon = Server.CreateObject("ADODB.Connection")
 
'Set an active connection to the Connection object using a DSN-less connection
adoCon.Open "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath("artform.mdb")
 
'Create an ADO recordset object
Set rsMasterRolodex = Server.CreateObject("ADODB.Recordset")
 
'Initialise the strSQL variable with an SQL statement to query the database
strSQL = "SELECT MASTER_Rolodex.* FROM MASTER_Rolodex WHERE ID_no=" & lngRecordNo
 
'Open the recordset with the SQL query 
rsMasterRolodex.Open strSQL, adoCon
%>
<html>
<head>
<title>ART Department Update Form</title>
</head>
 
<p align="center">
						<img border="0" src="../SEARCHES/images2/combo%20blade%20logos.gif" width="184" height="41" align="middle"><p align="center">
<font color="#004080">
<font face="Arial" style="font-size: 22pt"><b>ART Department UPDATE FORM</b><br>
</font><font face="Arial">To make an update, change the data in the forms and 
then click SUBMIT.</font><font face="Arial" style="font-size: 20pt">
</font></font><hr width="54%" color="#004080">
<body bgcolor="white" text="black"><form name="form" method="post" action="ARTupdate_entry.asp">
  <div align="center">
  <table border="0" cellspacing="0" width="535" height="750" id="table1">
	<tr>
		<td width="173"><font color="#004080"><b><font face="Arial">Name</font>:</b>&nbsp; 
		</font> </td>
		<td> 
		<input type="text" name="Name" maxlength="60" value="<% = rsMasterRolodex("Name") %>">  
  		</td>
	</tr>
	<tr>
		<td width="173">
  <font face="Arial" color="#004080">Phone:</font></td>
		<td> <input type="text" name="Phone" maxlength="60" value="<% = rsMasterRolodex("Phone") %>">
  		</td>
	</tr>
	<tr>
		<td width="173">
  <font color="#004080">
  <font face="Arial">When you need it:</font> </font> </td>
		<td> <input type="text" name="NeedIt" maxlength="60" value="<% = rsMasterRolodex("NeedIt") %>">  
  		</td>
	</tr>
	<tr>
		<td width="173">
  <font color="#004080">
  <font face="Arial">Date to run</font>:&nbsp; </font> </td>
		<td> <input type="text" name="DateRuns" maxlength="60" value="<% = rsMasterRolodex("DateRuns") %>">
  		</td>
	</tr>
	<tr>
		<td width="173">
  <font color="#004080">
  <font face="Arial">Headline</font>:&nbsp; </font> </td>
		<td> 
	<input type="text" name="Headline" maxlength="80" value="<% = rsMasterRolodex("Headline") %>" size="40"></td>
	</tr>
	<tr>
		<td width="173">
  <font color="#004080">
  <font face="Arial">Source Line</font>:&nbsp;&nbsp; </font> </td>
		<td> <input type="text" name="Source" maxlength="60" value="<% = rsMasterRolodex("Source") %>"></td>
	</tr>
	<tr>
		<td width="173">
  <font face="Arial" color="#004080">Chatter:</font></td>
		<td> <input type="text" name="Chatter" maxlength="20" value="<% = rsMasterRolodex("Chatter") %>"></td>
	</tr>
	<tr>
		<td width="173">
  <font face="Arial" color="#004080">Reference:</font></td>
		<td> <input type="text" name="Reference" maxlength="60" value="<% = rsMasterRolodex("Reference") %>"></td>
	</tr>
	<tr>
		<td width="173">
  <font face="Arial" color="#004080">Instructions:</font></td>
		<td> <input type="text" name="Instructions" maxlength="20" value="<% = rsMasterRolodex("Instructions") %>"></td>
	</tr>
	<tr>
		<td width="173">
  <font color="#004080">
  <font face="Arial">Submitted:</font> </font> </td>
		<td> <input type="text" name="Dateandtime" maxlength="60" value="<% = rsMasterRolodex("Dateandtime") %>"></td>
	</tr>
	<tr>
		<td width="173">
  <font face="Arial" color="#004080">Status:&nbsp;</font></td>
		<td> 
	<input type="text" name="Status" maxlength="80" value="<% = rsMasterRolodex("Status") %>" size="41"></td>
	</tr>
	<tr>
		<td width="173">&nbsp;</td>
		<td>
  <input type="submit" name="Submit" value="Submit UPDATE"></td>
	</tr>
	</table>
	</div>
	<p align="center">
  <br>
  &nbsp;  
  <br>
  	&nbsp; &nbsp;
  <br>
  <font face="Arial">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;  
  <br>
  	&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;
  <br>
  <br>
  	&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  <br>
  	&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  
  <br>
  	&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;
 <br>
  <font face="Arial">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</font>&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  
  <br>
  	<font face="Arial">&nbsp;&nbsp;</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
 <br>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
 <br>
  	<font face="Arial">&nbsp;&nbsp;</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
 <br>
  	<font face="Arial">&nbsp;</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
 <br>
  	&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
 <br>  <font face="Arial">&nbsp;</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
 <br>  <font face="Arial">&nbsp;&nbsp; &nbsp;</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; <font face="Arial">&nbsp;&nbsp;&nbsp;
	<br>
	&nbsp;
	</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
	<font face="Arial"><br>
&nbsp;&nbsp; </font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;
</p>
	<p align="center">
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
  <input type="hidden" name="ID_no" value="<% = rsMasterRolodex("ID_no") %>">
  &nbsp;</p>
</form>
<!-- End form code -->
</body>
</html>
<%
'Reset server objects
rsMasterRolodex.Close
Set rsMasterRolodex = Nothing
Set adoCon = Nothing
%>
 
Open in New Window Accept and Award Points Accept as Solution
[+][-]06.19.2008 at 06:21AM PDT, ID: 21821839

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Active Server Pages (ASP), Microsoft Access Database
Sign Up Now!
Solution Provided By: OnALearningCurve
Participating Experts: 1
Solution Grade: B
 
 
[+][-]06.19.2008 at 09:58AM PDT, ID: 21824115

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]06.19.2008 at 07:33PM PDT, ID: 21828044

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 7-day free trial to view this Administrative Comment or ask the Experts your question.

 
[+][-]06.20.2008 at 12:19AM PDT, ID: 21828983

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]06.20.2008 at 04:23AM PDT, ID: 21829962

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628