how do i delete all the data which is stored in the sql table????
i want to delete only the data present in one table without dropping the table when i click on the command button in vb6 plz help :(:(:(:( its really urgent
"Recordset.Delete" will only delete the active row. You either have to iterate through the recordset and advance the current row or do what @debasisdas says. Please don't post if you haven't tested your solution.
Noted. It didn't work in the test I did, so please share your scenario that DID work. We're all about learning here, I'm curious to see your complete solution.
I tested with VB6 using an ADODC control connected to a SQL2008 backend. If convenient, please post important details, including database engine, connection string (except passwords, of course :D), surrounding control types, and so on. Personally, I'm interested in solving the problem for the OP. If I can learn something along the way, that's a bonus.
sql = "DELETE FROM customers"
sq l= sql & " WHERE customerID='" & cid & "'"
on error resume next
if err<>0 then
MsgBox.Show "No update permissions!"
MsgBox.Show "Record " & cid & " was deleted!"
Hi. I have a form with list box : lst_product, datagridview : grd_order and button: btn_addline. lst_product has a list of product ids selected from database (MS Acess 2013) , grd_order is by default empty except for 2 headers and btn_addline adds rows to grd_order.
I am writing a java program that needs to execute shell commands, so I wrote a function that would take the command to execute as a string (ie: "mkdir ~/Folder1") and execute that command with the shell. Here is the function:
Runtime run = Runtime.getRuntime();
Process pr = ...
Hey, so I wanna ask how I need to create a method who will remove word if in that word is 2 same chars. Example: "Potato" in this word there is a 2 "o" chars so this word will need to be removed. "Forum" in this word there is no ...