esquima Posted November 26, 2007 at 04:58 AM Report Share #150382 Posted November 26, 2007 at 04:58 AM pessoal, tou a tentar inserir um novo registo na bd. o select corre bem o update tb, mas o insert nao...da me erro de sintaxe na instrução SELECT INTO é estranho pq ta tudo correcto Dim sSql As String Dim oDR As OleDbDataReader 'sSql = " SELECT pass From usernet WHERE user = '" & TextUser.Text & "'" sSql = "INSERT INTO usernet (user,pass) VALUES ('" & TextUser.Text & "','" & TextPass1.Text & "')" 'sSql = "UPDATE usernet Set pass =('" & TextPass1.Text & "') where user='" & TextUser.Text & "'" Dim ex As Exception Try oDR = abreConexao(sSql) oDR.Close() MsgBox("Novo Registo Web inserido com sucesso", MsgBoxStyle.Information) Catch ex MsgBox(ex.Message) End Try End Sub Link to comment Share on other sites More sharing options...
Asgorath Posted November 26, 2007 at 09:20 AM Report Share #150388 Posted November 26, 2007 at 09:20 AM Boas. Tenta retirar os parêntesis "The Dark Side Clouds Everthing. Impossible To See The Future Is."My rig: Intel Core 2 Quad Q9450 | abit IP35P | 4G Kingston 800 Mhz | XFX GeForce 9800 GX2 1G ddr3 | 2X WD5000AAJS 500Gb Sata 2 | PSU 600W || Caixa El-Diablo | Creative XMod Link to comment Share on other sites More sharing options...
esquima Posted November 26, 2007 at 02:54 PM Author Report Share #150434 Posted November 26, 2007 at 02:54 PM bem tentei de tudo e mais alguma coisa...nao deu nada--mto estranho mesmo..apaguei a tabela e voltei a faze-la e ja deu...coisa estranha 😛 Alguem percebe de C?? tenho aki 6 linhas de codigo que gostaria de passar para vb Link to comment Share on other sites More sharing options...
NuGuN Posted November 26, 2007 at 03:13 PM Report Share #150437 Posted November 26, 2007 at 03:13 PM Então posta essas linhas 😛 Cumps Link to comment Share on other sites More sharing options...
esquima Posted November 26, 2007 at 03:34 PM Author Report Share #150446 Posted November 26, 2007 at 03:34 PM for (int i = 0; i < GridView1.Rows.Count; i++) { CheckBox cb = (CheckBox)GridView1.Rows[i].Cells[0].FindControl("CheckBox1");//Gets the checkbox id in the grid. I assume that your checkbox is in the first column in your grid if (cb.Checked == true) { //Do something here when CheckBox = True } else { //Do something here when CheckBox = False} } } Link to comment Share on other sites More sharing options...
Asgorath Posted November 26, 2007 at 04:46 PM Report Share #150457 Posted November 26, 2007 at 04:46 PM Boas Isso não c é c# tenta converter usando a seguinte ferramenta http://labs.developerfusion.co.uk/convert/csharp-to-vb.aspx "The Dark Side Clouds Everthing. Impossible To See The Future Is."My rig: Intel Core 2 Quad Q9450 | abit IP35P | 4G Kingston 800 Mhz | XFX GeForce 9800 GX2 1G ddr3 | 2X WD5000AAJS 500Gb Sata 2 | PSU 600W || Caixa El-Diablo | Creative XMod Link to comment Share on other sites More sharing options...
esquima Posted November 26, 2007 at 07:14 PM Author Report Share #150487 Posted November 26, 2007 at 07:14 PM thanks asgorath esse site resolveu o meu problema 😛 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now