Click here to Skip to main content
15,904,503 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: Control to be focused on postback Pin
Kandepu Rajesh6-May-14 0:12
Kandepu Rajesh6-May-14 0:12 
GeneralRe: Control to be focused on postback Pin
Tom Marvolo Riddle6-May-14 0:54
professionalTom Marvolo Riddle6-May-14 0:54 
AnswerRe: Control to be focused on postback Pin
jkirkerx8-May-14 12:09
professionaljkirkerx8-May-14 12:09 
QuestionSwitching from PHP to ASP.NET Pin
Daniel Lieberwirth (BrainInBlack)4-May-14 22:38
professionalDaniel Lieberwirth (BrainInBlack)4-May-14 22:38 
AnswerRe: Switching from PHP to ASP.NET Pin
Peter Leow4-May-14 23:16
professionalPeter Leow4-May-14 23:16 
GeneralRe: Switching from PHP to ASP.NET Pin
Daniel Lieberwirth (BrainInBlack)4-May-14 23:25
professionalDaniel Lieberwirth (BrainInBlack)4-May-14 23:25 
AnswerRe: Switching from PHP to ASP.NET Pin
thatraja4-May-14 23:19
professionalthatraja4-May-14 23:19 
GeneralRe: Switching from PHP to ASP.NET Pin
Daniel Lieberwirth (BrainInBlack)4-May-14 23:29
professionalDaniel Lieberwirth (BrainInBlack)4-May-14 23:29 
GeneralRe: Switching from PHP to ASP.NET Pin
thatraja4-May-14 23:31
professionalthatraja4-May-14 23:31 
GeneralRe: Switching from PHP to ASP.NET Pin
Daniel Lieberwirth (BrainInBlack)4-May-14 23:36
professionalDaniel Lieberwirth (BrainInBlack)4-May-14 23:36 
GeneralRe: Switching from PHP to ASP.NET Pin
jkirkerx8-May-14 12:21
professionaljkirkerx8-May-14 12:21 
Generalinsert data to DB with MS SQL using Classic ASP Pin
Ye Htut4-May-14 19:15
Ye Htut4-May-14 19:15 
GeneralRe: insert data to DB with MS SQL using Classic ASP Pin
Schatak4-May-14 20:27
professionalSchatak4-May-14 20:27 
GeneralRe: insert data to DB with MS SQL using Classic ASP Pin
Ye Htut4-May-14 20:51
Ye Htut4-May-14 20:51 

<title>



AuthorID


Author Name





<%
dim Conn ' As Object
set Conn = Server.Createobject("ADODB.Connection")
Conn.ConnectionString = "Provider=SQLOLEDB; Data Source = (local); Initial Catalog = Test; User Id = sa; Password=as"
Conn.Open 'an error will occur here if the server/connection info is incorrect.

Dim MyRs 'As ADODB.Recordset
Set MyRs = Server.CreateObject("ADODB.Recordset")
MyRs.CursorLocation = 3 'adUseClient

Dim vAuthorID, vName,sql
vAuthorID = Request.Form(aid)
vName = Request.Form(aname)
' --note this is wide open to SQL injection better to use StoredProcedure instead:
sql="Insert into author(aid,aname) VALUES ('"& vAuthorID &"','" & vName &"')"
conn.Execute(sql)
conn.close
set sql = Nothing
response.Redirect("thankyou.asp")
End If
%>



Hello fri, plz look at my code. Error still happen in my code. Thz
GeneralRe: insert data to DB with MS SQL using Classic ASP Pin
Schatak4-May-14 20:58
professionalSchatak4-May-14 20:58 
GeneralRe: insert data to DB with MS SQL using Classic ASP Pin
Ye Htut5-May-14 3:11
Ye Htut5-May-14 3:11 
GeneralRe: insert data to DB with MS SQL using Classic ASP Pin
thatraja5-May-14 4:29
professionalthatraja5-May-14 4:29 
QuestionSubjectUserSid S-1-5-21-3532193094-2589986628-862158326-1002 how do i find out what the subject users name,tyhat owns that #? Pin
Member 107943654-May-14 13:05
Member 107943654-May-14 13:05 
AnswerRe: SubjectUserSid S-1-5-21-3532193094-2589986628-862158326-1002 how do i find out what the subject users name,tyhat owns that #? Pin
Richard MacCutchan4-May-14 22:20
mveRichard MacCutchan4-May-14 22:20 
QuestionSubjectUserSid S-1-5-21-3532193094-2589986628-862158326-1002 how do i find out what the subject users name,tyhat owns that #? Pin
Member 107943654-May-14 13:04
Member 107943654-May-14 13:04 
QuestionWhen my application idle for 20 minutes then they redirect to login page Pin
kuldeep10972-May-14 23:13
kuldeep10972-May-14 23:13 
AnswerRe: When my application idle for 20 minutes then they redirect to login page Pin
Ali Al Omairi(Abu AlHassan)4-May-14 1:00
professionalAli Al Omairi(Abu AlHassan)4-May-14 1:00 
QuestionCreate a comment system Pin
BL@CK H@CK$R2-May-14 17:08
BL@CK H@CK$R2-May-14 17:08 
AnswerRe: Create a comment system Pin
Peter Leow2-May-14 17:53
professionalPeter Leow2-May-14 17:53 
AnswerRe: Create a comment system Pin
BL@CK H@CK$R3-May-14 7:31
BL@CK H@CK$R3-May-14 7:31 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.