ObjectDataSource - data biding - asp.net
<p>Here the object "BookShop" has properties AuthorName and AuthorId of type "string", Is it possible to code a user defined class like "BookDetails" so that I can specify something like BookDetails.Author or </p>

<pre><code>&lt;form id="form1" runat="server"&gt;


&lt;asp:DropDownList ID="DropDownList1" runat="server" AutoPostBack="True"

    DataSourceID="ObjectDataSource1" DataTextField="AuthorName" DataValueField="AuthorId"&gt;

&lt;/asp:DropDownList&gt;



&lt;asp:ObjectDataSource ID="ObjectDataSource1" runat="server"

    SelectMethod="GetAuthors" TypeName="BookShop"&gt;

&lt;/asp:ObjectDataSource&gt;

 &lt;/form&gt;
</code></pre>
