Hello, I am trying to use the gridview to try to display data...this is kind of a work in progress as I don't know what best approach is that I should be taking to display the data or if I am even using the right control. I am trying to piece things together from some of the examples I can find. My questions are:
1. In the column named "img" is it possible to just hide that header and place the image next to the text?
2. Can those expanded columns be auto sized instead of manual sized?
3. Is there an example of a dropdown box in one of these expanded row?
Here is my rough code creating the expanded rows:
'create out custom datasource containing all the appsDim BusinessAppsDT As New DataTable("Apps")
With BusinessAppsDT
.Columns.Add("id", GetType(Guid))
.Columns.Add("img", GetType(Byte()))
.Columns.Add("name", GetType(String))
End With
For Each row As DataRow In dt.Rows
For Each itm As MyPortalObjects.Objects.ListItem In DeSerializeListview(Of MyPortalObjects.Objects.ListItem)(row("User_Needed_BusinessApps"))
BusinessAppsDT.Rows.Add(row("id"), itm.IconByteArray, itm.Name)
Next
Next
'gridview templates are the tabs?
Dim BusinessAppsTemplate As New GridViewTemplate
BusinessAppsTemplate.Caption = "Apps"
BusinessAppsTemplate.DataSource = BusinessAppsDT
gvQueue.Templates.Add(BusinessAppsTemplate)
Dim BusinessAppsRelation As New GridViewRelation(gvQueue.MasterTemplate)
With BusinessAppsRelation
.ChildTemplate = BusinessAppsTemplate
.ParentColumnNames.Add("id")
.ChildColumnNames.Add("id")
End With
gvQueue.Relations.Add(BusinessAppsRelation)
Dim BusinessAppsView As New HtmlViewDefinition()
With BusinessAppsView
.RowTemplate.Rows.Add(New RowDefinition())
.RowTemplate.Rows(0).Cells.Add(New CellDefinition("img", 3, 1, 3))
.RowTemplate.Rows(0).Cells.Add(New CellDefinition("name", 10, 1, 3))
End With
BusinessAppsTemplate.ViewDefinition = BusinessAppsView
This question can be deleted. I took a different approach.