Αρχή :: Ενότητες :: Scripting :: Απαντήσεις     
 

Forum

Update Fields, How? - Από {cyborg}

Mporei kapoios na mou pei pou einai to lathos?
Prospa8w edw kai kati wres na kanw update ta fields den mou bgazei opoiodhpote error, alla de kanei tipota(to field menei opws kataxorithike thn 1h fora)!
ta dokimasa ola!


<%
If AddRecord ="Submit" Then
If (trim(Artist)<>"") And (trim(Label)<>"") And (trim(Title)<>"") And (trim(Genre)<>"") And (trim(Year)<>"") Then
Dim OperatorsDBConn
Dim TmpRecordSet1
Dim strSql

Set OperatorsDBConn = Server.CreateObject("ADODB.Connection")
Set TmpRecordSet1 = Server.CreateObject("ADODB.RecordSet")
OperatorsDBConn.Open "DRIVER={Microsoft Access Driver (*.mdb)};DBQ=" & Server.Mappath("Records.mdb") & ";"
strSql = "UPDATE Records SET " _
& "Artist= '" & Artist &"', " _
& "Title= '"&Title&"', " _
& "Label= '"&Label&"', " _
& "Genre='"&Genre&"', " _
& "Comments='"&Comments&"', " _
& "Year='"&Year&"', "_
& "WHERE (ID=" & idtoken & ")"
TmpRecordSet1.Open Sql,OperatorsDBConn
Response.Redirect("records.asp")

%>

 


Απάντηση από:Alex

Κλείσε την σύνδεση και μετα δώσε
Response.Redirect("records.asp")



tip: Gr και διεθνή domain names με δωρεάν web hosting * F5 για νέο tip

   Πίσω στην προηγούμενη σελίδα






Η Εταιρία | Web Hosting | Domain names | Web Information | Υπηρεσίες | Resellers | Υποστήριξη |
Copyright © 2007–09 4GR.NETWORKS, All rights reserved.