Problem with update and delete statements

masktoon

New member
Joined
Nov 20, 2004
Messages
4
Programming Experience
3-5
hi ,

I am having a problem around here. I am using an OLEDB connection. I want to update the database with the new value.

I want to take user entry through a control and update the database value.

:eek: overall , please help me out and give the syntax for use of parameterized queries for Update & Delete Statements.
 
VB.NET:
 'cn is a connection
 'update statement
 dim cm as new oledbcommand("update table set name='" & textbox1.text & "'",cn)
 cm.executenonquery
 'delete statement
 dim cm as new oledbcommand("delete from table where name='" & textbox1.text & "'",cn)
 cm.executenonquery
 
Back
Top