Olá a todos, tenho a seguinte duvida, Protected Sub btn_guardar_Click(ByVal sender As Object, ByVal e As System.EventArgs)
Dim Nome As String
Dim Morada As String
Dim idpostal1 As Integer
Dim idpostal2 As Integer
Dim localidade As String
Dim Contribuinte As UInteger
Dim telefone As UInteger
Dim telemovel As UInteger
Dim email As String
Dim data As String
Dim SQLStmt As String
Nome = Trim(Txtnome.Text)
Morada = Trim(txtmorada.Text)
idpostal1 = CInt(txtpostal1.Text)
idpostal2 = CInt(txtpostal2.Text)
localidade = Trim(txtlocalidade.Text)
telefone = CUInt(txttelefone.Text)
telemovel = CUInt(txttelemovel.Text)
email = Trim(txtEmail.Text)
Contribuinte = CUInt(txtcontribuinte.Text)
data = Format(Today, "yyyy-MM-dd")
SQLStmt = "updatecommand cliente set Nome='" & Nome & "', morada='" & Morada & "', id_postal1=" & idpostal1 & ", localidade='" & localidade & "', telefone=" & telefone & ", telemovel=" & telemovel & ", email='" & email & "', contribuinte=" & Contribuinte & ", id_postal2=" & idpostal2 & " where nome_utilizador='" & Session("login") & "'"
MsgBox(SQLStmt)
conexao.Open()
comando = New SqlCommand(SQLStmt, conexao)
comando.ExecuteNonQuery()
conexao.Close()
MsgBox("Registo alterado com sucesso")
End Sub Não consigo prever algum erro, fiz da maneira como no Visual Basic, mas o incrivel é que não da nenhum erro, alguém me pode ajudar? Abraços