문제

Using devexpress, I placed an xtragridcontrol on the form, added some columns, then filled it with data:

gcCegek.DataSource = Nothing
ConnectToDb(fbconn, "public")
fbcommand.Connection = fbconn
fbcommand.CommandText = "select cegazon, rovidnev, varos, adoszam, konyvpnem, osszktg_forg from cegek order by cegazon"
fbadapter.SelectCommand = fbcommand
fbadapter.Fill(fbdataset)
gcCegek.DataSource = fbdataset
fbconn.Close()

I receive gridcontrol, but within the master-detail view; this means I have to click on the plus icon to see the data I wanted to show.

How do I remove the master-detail view so I can present a simple table with columns and rows?

도움이 되었습니까?

해결책

Set the GridControl.ShowOnlyPredefinedDetails property to true. This will prevent the grid from creating additional levels.

Update

Here are two solutions:

1) set the GridControl's DataMember property to the "cegazon" value

OR 2) set the gridControl's DataSource to the required DataTable

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top