Click here to Skip to main content
15,900,724 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Using Listbox help Pin
Sathesh Sakthivel5-Jul-07 19:21
Sathesh Sakthivel5-Jul-07 19:21 
QuestionRe: Using Listbox help Pin
benny777ex5-Jul-07 22:45
benny777ex5-Jul-07 22:45 
AnswerRe: Using Listbox help Pin
Sonia Gupta5-Jul-07 23:14
Sonia Gupta5-Jul-07 23:14 
QuestionRe: Using Listbox help Pin
benny777ex6-Jul-07 0:01
benny777ex6-Jul-07 0:01 
AnswerRe: Using Listbox help Pin
The ANZAC6-Jul-07 1:24
The ANZAC6-Jul-07 1:24 
GeneralRe: Using Listbox help Pin
benny777ex6-Jul-07 1:36
benny777ex6-Jul-07 1:36 
GeneralRe: Using Listbox help Pin
The ANZAC6-Jul-07 2:37
The ANZAC6-Jul-07 2:37 
QuestionDynamic DataGridView problems Pin
nz_fox5-Jul-07 14:57
nz_fox5-Jul-07 14:57 
I have a datagridview control on the form and I want to let the user to pick a table and popular the table to the datagridview. The codes I have that work except, everytime you populate the datagridview with a different table, it maintain the old table columns.
Here is my codes

 Dim mycommand As New SqlClient.SqlCommand<br />
        mycommand.Connection = myConn<br />
        Dim TableName As String = ComboBox2.SelectedItem<br />
        mycommand.CommandText = "Select * from " & TableName<br />
        myConn.Open()<br />
        Try<br />
            da = New SqlClient.SqlDataAdapter(mycommand)<br />
            ds.Clear()<br />
            da.Fill(ds)<br />
            Dim dt As New DataTable<br />
            dt = ds.Tables(0)<br />
            DataGridView1.DataSource = dt<br />
<br />
        Catch ex As Exception<br />
            Debug.Print(ex.ToString())<br />
            MsgBox(ex.ToString)<br />
        Finally<br />
            myConn.Close()<br />
        End Try<br />

I thought that must be something very simple that I'm missing.

AnswerRe: Dynamic DataGridView problems Pin
Polymorpher5-Jul-07 15:06
Polymorpher5-Jul-07 15:06 
QuestionAutomating code to update fill periodically Pin
Cory Kimble5-Jul-07 9:22
Cory Kimble5-Jul-07 9:22 
AnswerRe: Automating code to update fill periodically Pin
Christian Graus5-Jul-07 9:33
protectorChristian Graus5-Jul-07 9:33 
QuestionMaking a particular cell of datagrids uneditable [modified] Pin
hsprasain5-Jul-07 8:23
hsprasain5-Jul-07 8:23 
AnswerRe: Making some columns of datagrids uneditable Pin
aphei5-Jul-07 17:07
aphei5-Jul-07 17:07 
GeneralRe: Making some columns of datagrids uneditable Pin
hsprasain6-Jul-07 5:45
hsprasain6-Jul-07 5:45 
AnswerRe: Making some columns of datagrids uneditable Pin
Johan Hakkesteegt5-Jul-07 22:02
Johan Hakkesteegt5-Jul-07 22:02 
GeneralRe: Making some columns of datagrids uneditable Pin
hsprasain6-Jul-07 5:51
hsprasain6-Jul-07 5:51 
GeneralRe: Making some columns of datagrids uneditable Pin
Johan Hakkesteegt8-Jul-07 19:56
Johan Hakkesteegt8-Jul-07 19:56 
GeneralRe: Making some columns of datagrids uneditable Pin
hsprasain9-Jul-07 18:07
hsprasain9-Jul-07 18:07 
GeneralRe: Making some columns of datagrids uneditable Pin
Johan Hakkesteegt10-Jul-07 0:12
Johan Hakkesteegt10-Jul-07 0:12 
GeneralRe: Making some columns of datagrids uneditable Pin
hsprasain10-Jul-07 5:29
hsprasain10-Jul-07 5:29 
GeneralRe: Making some columns of datagrids uneditable Pin
Johan Hakkesteegt10-Jul-07 20:25
Johan Hakkesteegt10-Jul-07 20:25 
GeneralRe: Making some columns of datagrids uneditable Pin
hsprasain12-Jul-07 17:54
hsprasain12-Jul-07 17:54 
QuestionView and Review my looping code Pin
steve_rm5-Jul-07 7:27
steve_rm5-Jul-07 7:27 
AnswerRe: View and Review my looping code Pin
Christian Graus5-Jul-07 7:33
protectorChristian Graus5-Jul-07 7:33 
AnswerRe: View and Review my looping code Pin
kubben5-Jul-07 7:33
kubben5-Jul-07 7:33 

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.