dim cnn as new adodb.connectioncnn.open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=yourDB.mdb; Persist Security Info=False" cnn.execute "create table new (X long, A long, B long, C Long)" cnn.execute "insert into new (A, B, C) values(0, 0, 0)" cnn.execute "insert into new (A, B, C) values(0, 0, 0)" cnn.execute "insert into new (A, B, C) values(" & val(text1) & "," & val(text2) & "," & val(text3) ")"
Dim DB As Database Set DB=Opendatabase(App.path & "\Mydb.mdb") DB.Execute "Create Table new(X Integer, A Integer, B Integer, C Integer)" DB.Execute "Insert Into new (A, B, C) values(0, 0, 0)" DB.Execute "Insert Into new (A, B, C) values(0, 0, 0)" DB.Execute "Insert Into new (A, B, C) values(" & val(text1) & "," & val(text2) & "," & val(text3) ")" DB.Close
删除当前COMBO中的元素: Combo1.RemoveItem Combo1.ListIndex
DB.Execute "Insert Into new (A, B, C) values(" & val(text1) & "," & val(text2) & "," & val(text3) ")" 我在VB中调试不通过,这句不对嘛!Combo1.RemoveItem Combo1.ListIndex也不对!参数也不对!还有我想在以有的表中插入数据怎么办?请指教!
cnn.execute "create table new (X long, A long, B long, C Long)"
cnn.execute "insert into new (A, B, C) values(0, 0, 0)"
cnn.execute "insert into new (A, B, C) values(0, 0, 0)"
cnn.execute "insert into new (A, B, C) values(" & val(text1) & "," & val(text2) & "," & val(text3) ")"
!另外怎样删除当前COMBO中的元素(COMBO.REMOVEITEM?)XIE
Set DB=Opendatabase(App.path & "\Mydb.mdb")
DB.Execute "Create Table new(X Integer, A Integer, B Integer, C Integer)"
DB.Execute "Insert Into new (A, B, C) values(0, 0, 0)"
DB.Execute "Insert Into new (A, B, C) values(0, 0, 0)"
DB.Execute "Insert Into new (A, B, C) values(" & val(text1) & "," & val(text2) & "," & val(text3) ")"
DB.Close
Combo1.RemoveItem Combo1.ListIndex
我在VB中调试不通过,这句不对嘛!Combo1.RemoveItem Combo1.ListIndex也不对!参数也不对!还有我想在以有的表中插入数据怎么办?请指教!