Home All Groups Group Topic Archive Search About

FormView/Repeater/ Eval(FormView data)

Author
15 Jun 2006 11:21 PM
David Thielen
Hi;

I have (lots of tags not shown):
    <asp:FormView ID="EditUser" runat="server" DataSourceID="UserData"
DataKeyNames="username">
works: <%# Eval("UserName") %>
<asp:Repeater ID="mapRows" runat="server" DataSourceID="RoleData">
fails: <%# Eval("UserName") %>
</asp:Repeater>
</asp:FormView>

How do I get at data bound to the outer FormView inside the Repeater?

--
thanks - dave
david_at_windward_dot_net
http://www.windwardreports.com

Author
16 Jun 2006 9:20 AM
Steven Cheng[MSFT]
Hello Dave,

Thanks for your posting.

From your description, you'd like to access the parent container's
databinding context(DataItem) in the nested databound control's databinding
code, correct?

Based on my understanding, it is not quite easy to do so since the
ItemDatabound of template databound control only contains the current
databinding context's info.  What's the detailed scenario of your
databinding page, are you dealing with some master/detail   or parent/child
table data?   I think we may look for some other approach to workaround it?

Please feel free to post here.

Regards,

Steven Cheng
Microsoft MSDN Online Support Lead


==================================================

When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.

==================================================


This posting is provided "AS IS" with no warranties, and confers no rights.



Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
Author
16 Jun 2006 7:56 PM
David Thielen
Hi;

Yes, that is exactly what I want. If it can't be done in the aspx I can
easily do it in the code behind.

--
thanks - dave
david_at_windward_dot_net
http://www.windwardreports.com



Show quoteHide quote
"Steven Cheng[MSFT]" wrote:

> Hello Dave,
>
> Thanks for your posting.
>
> From your description, you'd like to access the parent container's
> databinding context(DataItem) in the nested databound control's databinding
> code, correct?
>
> Based on my understanding, it is not quite easy to do so since the
> ItemDatabound of template databound control only contains the current
> databinding context's info.  What's the detailed scenario of your
> databinding page, are you dealing with some master/detail   or parent/child
> table data?   I think we may look for some other approach to workaround it?
>
> Please feel free to post here.
>
> Regards,
>
> Steven Cheng
> Microsoft MSDN Online Support Lead
>
>
> ==================================================
>
> When responding to posts, please "Reply to Group" via your newsreader so
> that others may learn and benefit from your issue.
>
> ==================================================
>
>
> This posting is provided "AS IS" with no warranties, and confers no rights.
>
>
>
> Get Secure! www.microsoft.com/security
> (This posting is provided "AS IS", with no warranties, and confers no
> rights.)
>
>