HI,please help
i dont understand what i am doing wrong.I have a dataset and a datagrid.I amm trying to retrieve dataset contents but all i get is the heading row. I have checked my dataset, it has rows in it.
here is my page_load
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'Put user code to initialize the page here
Dim dsView As New DataSet
If Not Page.IsPostBack Then
dsView = IPFunc.ViewAllPlacements()
dgView.DataSource = dsView
dgView.Visible = True
dgView.DataBind()
End If
End Sub
Please helpPerhaps dsView is returning no datarows?Perhaps dsView is returning no datarows?
Yep, what Mhuk said.
Try putting a breakpoint on the page load at:
dgView.DataSource = dsView
and type in the the following in command window and press enter:
? dsView.Tables(0).Rows.Count
If the value is zero, there lies your problem, your IPFunc.ViewAllPlacements is returning zero rows.
i dont understand what i am doing wrong.I have a dataset and a datagrid.I amm trying to retrieve dataset contents but all i get is the heading row. I have checked my dataset, it has rows in it.
here is my page_load
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'Put user code to initialize the page here
Dim dsView As New DataSet
If Not Page.IsPostBack Then
dsView = IPFunc.ViewAllPlacements()
dgView.DataSource = dsView
dgView.Visible = True
dgView.DataBind()
End If
End Sub
Please helpPerhaps dsView is returning no datarows?Perhaps dsView is returning no datarows?
Yep, what Mhuk said.
Try putting a breakpoint on the page load at:
dgView.DataSource = dsView
and type in the the following in command window and press enter:
? dsView.Tables(0).Rows.Count
If the value is zero, there lies your problem, your IPFunc.ViewAllPlacements is returning zero rows.