Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I have simple application with FormView and SQLDataSource. When I check "Enable dynamic data support" I get following error:

Could not determine a MetaTable. A MetaTable could not be determined for

the data source 'SqlDataSource1' and one could not be inferred from the request URL. Make sure that the table is mapped to the dats source, or that the data source is configured with a valid context type and table name, or that the request is part of a registered DynamicDataRoute.

Any ideas?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
181 views
Welcome To Ask or Share your Answers For Others

1 Answer

For me, it turns out that in my grid view, the columns were bound as an "asp:DynamicField", not as a "asp:BoundField"

ie

changing my columns from something like so:

<Columns>
  <asp:DynamicField DataField="Id" HeaderText="Id" />
</Columns>

to this:

<Columns>
  <asp:BoundField DataField="Id" HeaderText="Id" />
</Columns>

fixed it ;-)


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...