Click here to Skip to main content
15,912,082 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: How to check if a file exists then delete it in vb.net 2005? Pin
Johan Hakkesteegt4-Jun-09 1:32
Johan Hakkesteegt4-Jun-09 1:32 
GeneralRe: How to check if a file exists then delete it in vb.net 2005? Pin
Dave Kreskowiak4-Jun-09 3:30
mveDave Kreskowiak4-Jun-09 3:30 
AnswerRe: How to check if a file exists then delete it in vb.net 2005? Pin
Ashfield4-Jun-09 1:40
Ashfield4-Jun-09 1:40 
GeneralRe: How to check if a file exists then delete it in vb.net 2005? Pin
Striker.dbz4-Jun-09 4:03
Striker.dbz4-Jun-09 4:03 
GeneralRe: How to check if a file exists then delete it in vb.net 2005? Pin
Jon_Boy4-Jun-09 7:31
Jon_Boy4-Jun-09 7:31 
GeneralRe: How to check if a file exists then delete it in vb.net 2005? Pin
Ashfield4-Jun-09 8:53
Ashfield4-Jun-09 8:53 
GeneralRe: How to check if a file exists then delete it in vb.net 2005? Pin
Jon_Boy5-Jun-09 2:05
Jon_Boy5-Jun-09 2:05 
QuestionInsert Values Into Database By Textbox Issues Pin
eginteractive3-Jun-09 15:25
eginteractive3-Jun-09 15:25 
Hey all, I've been working with making a client to insert / delete ect. from a database, and I can't get text fields to insert values into a database for some strange reason.

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles button1.Click
    Dim sqlconn As New SqlClient.SqlConnection
    sqlconn.ConnectionString = "Server=[removed];Database=erik_asp;Uid=asp;Pwd=[removed for security purposes];"
    Try
        sqlconn.Open()
    Catch ex As Exception
        MsgBox("Could not connect!", MsgBoxStyle.Critical, "Connection Error!")
    End Try
    If sqlconn.State = 1 Then
        Dim sqlconnecter As New SqlCommand( _
   "INSERT INTO [Team] ([position], [name], [email]) VALUES (" & positionbx.Text & ", " & usernamebx.Text & ", " & emailbx.Text & "))", sqlconn)
        sqlconnecter.ExecuteNonQuery()
        sqlconn.Close()
    End If
End Sub


It returns this error:

The name 'blahblahblahtext' is not permitted in this context. Only constants, expressions, or variables allowed here. Column names are not permitted.


This happens with all the text boxes.

Please note I am able to easily connect and view current data in the grid, I just can't insert this data and it's starting to irritate me.
AnswerRe: Insert Values Into Database By Textbox Issues Pin
Luc Pattyn3-Jun-09 15:36
sitebuilderLuc Pattyn3-Jun-09 15:36 
GeneralRe: Insert Values Into Database By Textbox Issues Pin
eginteractive3-Jun-09 15:44
eginteractive3-Jun-09 15:44 
GeneralRe: Insert Values Into Database By Textbox Issues Pin
Luc Pattyn3-Jun-09 15:52
sitebuilderLuc Pattyn3-Jun-09 15:52 
GeneralRe: Insert Values Into Database By Textbox Issues Pin
eginteractive3-Jun-09 16:36
eginteractive3-Jun-09 16:36 
GeneralRe: Insert Values Into Database By Textbox Issues Pin
Jon_Boy4-Jun-09 7:32
Jon_Boy4-Jun-09 7:32 
Questionhow can use help.showpopup() method to display non unicode text ( arabic text ) in Popup window in vb 2005 applications Pin
samy ansara3-Jun-09 6:47
samy ansara3-Jun-09 6:47 
AnswerRe: how can use help.showpopup() to display non unicode text ( arabic text ) in Popup window in vb 2005 Pin
Christian Graus3-Jun-09 10:34
protectorChristian Graus3-Jun-09 10:34 
GeneralRe: how can use help.showpopup() to display non unicode text ( arabic text ) in Popup window in vb 2005 Pin
Dave Kreskowiak3-Jun-09 17:13
mveDave Kreskowiak3-Jun-09 17:13 
GeneralRe: how can use help.showpopup() to display non unicode text ( arabic text ) in Popup window in vb 2005 Pin
Christian Graus3-Jun-09 21:06
protectorChristian Graus3-Jun-09 21:06 
GeneralRe: how can use help.showpopup() to display non unicode text ( arabic text ) in Popup window in vb 2005 Pin
David Skelly3-Jun-09 22:29
David Skelly3-Jun-09 22:29 
GeneralRe: how can use help.showpopup() to display non unicode text ( arabic text ) in Popup window in vb 2005 Pin
Christian Graus3-Jun-09 23:19
protectorChristian Graus3-Jun-09 23:19 
GeneralRe: how can use help.showpopup() to display non unicode text ( arabic text ) in Popup window in vb 2005 Pin
Dave Kreskowiak4-Jun-09 1:24
mveDave Kreskowiak4-Jun-09 1:24 
QuestionHow to use a an environment variable as argument to an program using shell command in VB.net 2005? Pin
Striker.dbz3-Jun-09 5:12
Striker.dbz3-Jun-09 5:12 
AnswerRe: How to use a an environment variable as argument to an program using shell command in VB.net 2005? Pin
Kschuler3-Jun-09 5:14
Kschuler3-Jun-09 5:14 
GeneralRe: How to use a an environment variable as argument to an program using shell command in VB.net 2005? Pin
Striker.dbz3-Jun-09 5:18
Striker.dbz3-Jun-09 5:18 
GeneralRe: How to use a an environment variable as argument to an program using shell command in VB.net 2005? Pin
Kschuler3-Jun-09 5:21
Kschuler3-Jun-09 5:21 
GeneralRe: How to use a an environment variable as argument to an program using shell command in VB.net 2005? Pin
Striker.dbz3-Jun-09 5:49
Striker.dbz3-Jun-09 5:49 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.