pschiff
October 16th, 2006, 04:46 PM
hi
I get the following error when I create a gridview and link it to a simple xmldatasource:
there was an error rendering the control.
The data source for GridView with id 'GridView1' did not have any properties or attributes from which to generate columns. Ensure that your data source has content.
then when i run the form, i get an exception:
The data source for GridView with id 'GridView1' did not have any properties or attributes from which to generate columns. Ensure that your data source has content.
xml:
<?xml version="1.0" encoding="utf-8"?>
<messages>
<message>
<name>Ping Nifty Tools</name>
<text>**** Item started ****</text>
<timeStamp>10-15-2006 18:13:02</timeStamp>
<type>5</type>
<typeText>n/a</typeText>
<status>Unknown</status>
</message>
</messages>
-----------------
<asp:XmlDataSource ID="OpMsgXmlDataSource" runat="server" DataFile="~/App_Data/OP_MSGS.XML">
</asp:XmlDataSource>
<asp:GridView ID="GridView1" runat="server" DataSourceID="OpMsgXmlDataSource">
</asp:GridView>
any ideas?
I get the following error when I create a gridview and link it to a simple xmldatasource:
there was an error rendering the control.
The data source for GridView with id 'GridView1' did not have any properties or attributes from which to generate columns. Ensure that your data source has content.
then when i run the form, i get an exception:
The data source for GridView with id 'GridView1' did not have any properties or attributes from which to generate columns. Ensure that your data source has content.
xml:
<?xml version="1.0" encoding="utf-8"?>
<messages>
<message>
<name>Ping Nifty Tools</name>
<text>**** Item started ****</text>
<timeStamp>10-15-2006 18:13:02</timeStamp>
<type>5</type>
<typeText>n/a</typeText>
<status>Unknown</status>
</message>
</messages>
-----------------
<asp:XmlDataSource ID="OpMsgXmlDataSource" runat="server" DataFile="~/App_Data/OP_MSGS.XML">
</asp:XmlDataSource>
<asp:GridView ID="GridView1" runat="server" DataSourceID="OpMsgXmlDataSource">
</asp:GridView>
any ideas?