Click here to Skip to main content
15,891,905 members
Home / Discussions / Visual Basic
   

Visual Basic

 
AnswerRe: Text_Changed is not working Pin
_mubashir3-May-07 0:52
_mubashir3-May-07 0:52 
GeneralRe: Text_Changed is not working Pin
TheEagle3-May-07 6:31
TheEagle3-May-07 6:31 
AnswerRe: Text_Changed is not working Pin
Guffa3-May-07 1:48
Guffa3-May-07 1:48 
GeneralRe: Text_Changed is not working Pin
TheEagle3-May-07 7:00
TheEagle3-May-07 7:00 
Questioncombo in datagridview Pin
aphei2-May-07 22:14
aphei2-May-07 22:14 
AnswerRe: combo in datagridview Pin
Sonia Gupta2-May-07 22:57
Sonia Gupta2-May-07 22:57 
AnswerRe: combo in datagridview Pin
Rupesh Kumar Swami2-May-07 23:24
Rupesh Kumar Swami2-May-07 23:24 
AnswerRe: combo in datagridview Pin
RichFeldman3-May-07 8:10
RichFeldman3-May-07 8:10 
I'm not sure if this will answer your question, but the following code segment first creates a DataTable containing values for my combo box, then creates a column that is inserted into a datagrid.


Dim typeDesc As New DataTable
Dim dr As DataRow

typeDesc.Columns.Add("Indx", Type.GetType("System.Int32")) '0
typeDesc.Columns.Add("Desc", Type.GetType("System.String")) '1
dr = typeDesc.NewRow()
dr(0) = 0 : dr(1) = "Rural"
typeDesc.Rows.Add(dr)
dr = typeDesc.NewRow()
dr(0) = 1 : dr(1) = "Suburban"
typeDesc.Rows.Add(dr)
dr = typeDesc.NewRow()
dr(0) = 2 : dr(1) = "Urban"
typeDesc.Rows.Add(dr) ' datatable giving values type

newCol = New DataGridViewComboBoxColumn
newCol.Width = 90
newCol.HeaderText = "Parcel Type"
newCol.DataSource = typeDesc
newCol.ValueMember = "Indx"
newCol.DisplayMember = "Desc"
dgvTasks.Columns.Insert(2, newCol)



The dgvTasks is the name of the datagrid in which the combo will appear.



Rich Feldman

GeneralRe: combo in datagridview Pin
aphei3-May-07 15:41
aphei3-May-07 15:41 
Questionhow to link outlook through vb.net Pin
shalinikannan2-May-07 21:06
shalinikannan2-May-07 21:06 
AnswerRe: how to link outlook through vb.net Pin
Sonia Gupta2-May-07 21:10
Sonia Gupta2-May-07 21:10 
AnswerRe: how to link outlook through vb.net Pin
Rupesh Kumar Swami2-May-07 23:43
Rupesh Kumar Swami2-May-07 23:43 
AnswerRe: how to link outlook through vb.net Pin
Dave Kreskowiak3-May-07 3:33
mveDave Kreskowiak3-May-07 3:33 
Questionconnect Vb To Ms Exel Pin
yoga budiman2-May-07 21:05
yoga budiman2-May-07 21:05 
AnswerRe: connect Vb To Ms Exel Pin
Sonia Gupta2-May-07 21:13
Sonia Gupta2-May-07 21:13 
Questionhelp required about minimize and maximize window from through codig Pin
Suhail Shahab2-May-07 20:12
Suhail Shahab2-May-07 20:12 
AnswerRe: help required about minimize and maximize window from through codig Pin
Christian Graus2-May-07 20:20
protectorChristian Graus2-May-07 20:20 
AnswerRe: help required about minimize and maximize window from through codig Pin
Chatura Dilan2-May-07 20:23
Chatura Dilan2-May-07 20:23 
GeneralRe: help required about minimize and maximize window from through codig Pin
Suhail Shahab6-May-07 21:01
Suhail Shahab6-May-07 21:01 
QuestionOLEDB vs SQLClient Pin
Sujit Mandal2-May-07 20:09
Sujit Mandal2-May-07 20:09 
AnswerRe: OLEDB vs SQLClient Pin
Sonia Gupta2-May-07 20:12
Sonia Gupta2-May-07 20:12 
AnswerRe: OLEDB vs SQLClient Pin
Dave Kreskowiak3-May-07 3:30
mveDave Kreskowiak3-May-07 3:30 
QuestionAPI Functions Pin
Mkanchha2-May-07 19:09
Mkanchha2-May-07 19:09 
AnswerRe: API Functions Pin
Christian Graus2-May-07 19:15
protectorChristian Graus2-May-07 19:15 
AnswerRe: API Functions Pin
Nouman Bhatti2-May-07 19:18
Nouman Bhatti2-May-07 19:18 

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.