[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

microsoft.public.dotnet.framework.aspnet.buildingcontrols

Accessing the Field of a Bind Expression at runtime.

dotNetProfessional

10/21/2006 10:39:00 AM

Greetings

I'm currently attempting to write a control that will extend functionality
of databound controls (ie TextBox etc). However, while I can access the
DataSource the control is bound to. I cant seem to identify which property
of the DataSource the control has been bound to.

For example:

<asp:TextBox ID="ABNTextBox" runat="server" Text='<%# Bind("ABN") %>'>
</asp:TextBox>

In this example I want to know at runtime that this text box is bound to the
property/field 'ABN'.

I would appreciate any feedback on this issue...
--
Garry McGlennon
MCSD, MCSD.NET
1 Answer

cld

2/25/2007 6:36:00 PM

0

dotNetProfessional wrote:
> Greetings
>
> I'm currently attempting to write a control that will extend functionality
> of databound controls (ie TextBox etc). However, while I can access the
> DataSource the control is bound to. I cant seem to identify which property
> of the DataSource the control has been bound to.
>
> For example:
>
> <asp:TextBox ID="ABNTextBox" runat="server" Text='<%# Bind("ABN") %>'>
> </asp:TextBox>
>
> In this example I want to know at runtime that this text box is bound to the
> property/field 'ABN'.
>
> I would appreciate any feedback on this issue...
If you are still listening, the property must be attributed for the data
binding mechanism.