Both DataSource and DataSourceID are defined on 'DetailsView1'.

Mar 14 2012 9:24 AM
I am trying to pull data from the database using simple details view and oledb access database.


If Not IsPostBack Then

Try

ReturnDataset(


Dim ds As New DataSet"Select * from ProjectDetails", "mytbl")If Not ds Is Nothing Then DetailsView1.DataSourceID =
Nothing DetailsView1.DataSource = ds
DetailsView1.DataBind()


End If



Catch ex As ExceptionEnd Try

End If


<asp:DetailsView ID="DetailsView1" runat="server" Height="50px" Width="125px">


</asp:DetailsView>

I keep getting this annoying exception and nothing seems to resolve my problem. Please help:-(

Answers (2)