내 액세스 데이터베이스를 업데이트해야이 코드를 가지고,하지만 난라는 오류가 계속 :Visual Basic에서 2010 오류
이테이블 때문에 regists을 변경하거나 삭제할 그렇게 할 수 없습니다 'MembrosCompasso'에 관련된 레코드가 있습니다.
Dim query1 As String = "UPDATE MembrosCompasso SET [email protected]_bi WHERE MembrosCompasso.BI=Membros.BI" ' [email protected], Membros.Mae=mae WHERE [email protected]" Dim query As String = "UPDATE Membros SET [email protected]_bi, [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected] WHERE [email protected]" con.Close() con.Open() Dim command As New OleDbCommand(query, con) Dim command1 As New OleDbCommand(query1, con) ' Indicação dos parâmetros que serão actualizados command1.Parameters.Add("@compass_bi", OleDbType.VarChar).Value = BI.Text command.Parameters.Add("@num_bi", OleDbType.VarChar).Value = BI.Text command.Parameters.Add("@nome", OleDbType.VarChar).Value = Nome.Text command.Parameters.Add("@hablitacoes", OleDbType.VarChar).Value = hablitacoes.Text command.Parameters.Add("@contribuinte", OleDbType.VarChar).Value = ncront.Text command.Parameters.Add("@telemov", OleDbType.VarChar).Value = telmov.Text command.Parameters.Add("@natnasc", OleDbType.VarChar).Value = datnasc.Text command.Parameters.Add("@localnasc", OleDbType.VarChar).Value = NascLocal.Text command.Parameters.Add("@databapt", OleDbType.VarChar).Value = DataBapt.Text command.Parameters.Add("@localbapt", OleDbType.VarChar).Value = LocalBapt.Text command.Parameters.Add("@sexo", OleDbType.VarChar).Value = sexo.Text command.Parameters.Add("@natu", OleDbType.VarChar).Value = natu.Text command.Parameters.Add("@prof", OleDbType.VarChar).Value = profi.Text command.Parameters.Add("@estadciv", OleDbType.VarChar).Value = estciv.Text command.Parameters.Add("@datacas", OleDbType.VarChar).Value = datcas.Text command.Parameters.Add("@localcas", OleDbType.VarChar).Value = localcas.Text command.Parameters.Add("@notas", OleDbType.VarChar).Value = notas.Text command.Parameters.Add("@email", OleDbType.VarChar).Value = email.Text command.Parameters.Add("@BI", OleDbType.VarChar).Value = numero_BI
내 액세스 DB 스키마 here의 스크린 샷이 있습니다 :
이
내 코드입니다.
thanx 문제가있는 – user1341926