Click here to Skip to main content
15,892,005 members
Home / Discussions / Database
   

Database

 
Questiontext in multiline. Pin
gvjanardhan26-Aug-05 2:23
sussgvjanardhan26-Aug-05 2:23 
AnswerRe: text in multiline. Pin
SeMartens26-Aug-05 2:47
SeMartens26-Aug-05 2:47 
AnswerRe: text in multiline. Pin
Colin Angus Mackay26-Aug-05 11:31
Colin Angus Mackay26-Aug-05 11:31 
AnswerRe: text in multiline. Pin
softty28-Aug-05 7:41
softty28-Aug-05 7:41 
Questionshowing parts of a table in datagrid Pin
nirdanon26-Aug-05 2:22
nirdanon26-Aug-05 2:22 
AnswerRe: showing parts of a table in datagrid Pin
SeMartens26-Aug-05 3:00
SeMartens26-Aug-05 3:00 
GeneralRe: showing parts of a table in datagrid Pin
Not Active26-Aug-05 3:44
mentorNot Active26-Aug-05 3:44 
GeneralRe: showing parts of a table in datagrid Pin
nirdanon26-Aug-05 5:16
nirdanon26-Aug-05 5:16 
thanks for the quick reply,

I'm using WindowsApplication and the datagrid is filled at run time.

i have a function which executes a query and return datatable
this datatable (some columns of this table) should be the datasource for the datagrid.

I tried to use the TableStyle like this whit no success

QueryStr = QueryStr + "select * from Trainee "
DT = db.selectQuery(QueryStr) ' returns datatable


Dim TS As New DataGridTableStyle
Dim CS As New DataGridTextBoxColumn
TS.MappingName = "UpdateTable"

CS = New DataGridTextBoxColumn
CS.MappingName = "FirstName"
CS.Width = 50
TS.GridColumnStyles.Add(CS)

CS = New DataGridTextBoxColumn
CS.MappingName = "LastName"
CS.Width = 50
TS.GridColumnStyles.Add(CS)

CS = New DataGridTextBoxColumn
CS.MappingName = "ID"
CS.Width = 50
TS.GridColumnStyles.Add(CS)

CS = New DataGridTextBoxColumn
CS.MappingName = "Mobile"
CS.Width = 50
TS.GridColumnStyles.Add(CS)

UpdateGrid.TableStyles.Add(TS)
UpdateGrid.DataSource = DT

how shpuld i connect the datasource?

thanks
nir.



GeneralRe: showing parts of a table in datagrid Pin
SeMartens26-Aug-05 5:28
SeMartens26-Aug-05 5:28 
GeneralRe: showing parts of a table in datagrid Pin
Anonymous28-Aug-05 3:39
Anonymous28-Aug-05 3:39 
GeneralRe: showing parts of a table in datagrid Pin
miah alom26-Aug-05 11:09
miah alom26-Aug-05 11:09 
GeneralRe: showing parts of a table in datagrid Pin
Anonymous28-Aug-05 3:39
Anonymous28-Aug-05 3:39 
QuestionAlias for table names Pin
smita_roy26-Aug-05 1:45
smita_roy26-Aug-05 1:45 
AnswerRe: Alias for table names Pin
Not Active26-Aug-05 3:47
mentorNot Active26-Aug-05 3:47 
AnswerRe: Alias for table names Pin
softty28-Aug-05 8:27
softty28-Aug-05 8:27 
Questiondynamic datasource on reporting services Pin
Ali Sapanci25-Aug-05 23:18
Ali Sapanci25-Aug-05 23:18 
AnswerRe: dynamic datasource on reporting services Pin
Ali Sapanci28-Aug-05 22:28
Ali Sapanci28-Aug-05 22:28 
Questionquerying a Acces DataBase Pin
Binary011025-Aug-05 21:26
Binary011025-Aug-05 21:26 
AnswerRe: querying a Acces DataBase Pin
beatles169227-Aug-05 2:22
beatles169227-Aug-05 2:22 
QuestionMore info on: Error Could Not Lock File Pin
Javolin25-Aug-05 12:28
Javolin25-Aug-05 12:28 
GeneralMDAC Sdk 2.8 Help Pin
dvptUml24-Aug-05 13:46
dvptUml24-Aug-05 13:46 
GeneralRecord locking ADO -net Pin
HahnTech24-Aug-05 9:47
HahnTech24-Aug-05 9:47 
GeneralRe: Record locking ADO -net Pin
miah alom25-Aug-05 8:36
miah alom25-Aug-05 8:36 
GeneralRe: Record locking ADO -net Pin
HahnTech25-Aug-05 8:51
HahnTech25-Aug-05 8:51 
GeneralRe: Record locking ADO -net Pin
Rob Graham26-Aug-05 11:48
Rob Graham26-Aug-05 11:48 

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.