Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Password a Delete Record Cmd Button

Status
Not open for further replies.

Omono

MIS
Apr 20, 2001
24
US
I have a computer inventory database that uses forms to navigate/edit data. I have a delete record button on the main form. Pressing the delete button calls up a form prompting for a password that looks like an inputbox but is a text box so I could use the password mask (*****). My problem is that this deletes the first record in the table, not the record I'm viewing on the main form. Any suggestions? Thanks

ofreeman
 
You could issue an SQL Delete command with a parameter to insure you are deleting the correct record.

DELETE FROM TableName WHERE Field1 = me.fieldNameFromform

I've used it before... seems to work... syntax may not be 100%. Steve Medvid
"IT Consultant & Web Master"
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top