请帮助一下!
请帮看一下:
Dim conn As New SqlConnection()
conn.ConnectionString = "server=localhost;database=mms;user id=login_gz;password=gz1508;"
conn.Open()
Dim objadpt As New SqlDataAdapter()
objadpt.SelectCommand = New SqlCommand("select * from bjapi", conn)
Dim ds As New DataSet()
objadpt.Fill(ds, "bjapi")
conn.Close()
Dim tab_bjapi As DataTable = ds.Tables("bjapi")
objadpt.InsertCommand.CommandText = "insert into bjapi (lastname,title,content,status,result,ex01,ex02) values('1','201205工资','3','4','5','2KM000000O','7')"
objadpt.Update(ds, "bjapi")
ds.AcceptChanges()
怎么弄也写不进数据库表
多谢了!
------解决方案--------------------"insert into tab_bjapi (lastname,title,content,status,result,ex01,ex02) values('1','201205工资','3','4','5','2KM000000O','7')"
这样修改后,也是不行。
------解决方案--------------------该回复于2012-08-14 17:24:00被版主删除