|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
allow someone to edit a form
Hi
I have a form which I would like to allow a customer to edit/update. I need to populate the text boxes with retrieved data and then allow customer to select 'update' button. I can't figure out the syntax to place the retrieved value within an input box. I have this so far, which obviously doesn't work - double quotes etc. Tried double and single quotes but no value appears. Also tried placing retrieved value within variable, but didn';t work either. <input type="text" name="FirstName" value="<%=rsdetails("FirstName")%>" Sure it's very simple.. Thanks! Lee |
|
#2
|
|||
|
|||
|
The first thing you must do is, like you say, retrieve the data that you need(the ones that'll go into the <textboxes>.
In order to do that, you'll have to create and SQL Query. Now since your SQL Query will look something like: (I'm assuming it's gonna look like that) SELECT Field1, Field2, ... FROM MyTable WHERE someID = 19 The 19 here is only an example of a uniqueID. You do understand that Query *should* only bring back *one* record right? If that's the case then you don't need to/won't have to *loop* inside your recordset right? (because you only have one record) Now because of this, I strongly recommand putting the data from that *one* record into variables. Only then use these variables to put inside your <form>...</form>. So...this is an example of the top of my head, it is NOT tested but should give you an idea: Download the attach file I've sent, all the code is in there and it should be trivial... Hope this helps! Sincerely Vlince |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ASP Programming > allow someone to edit a form |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|