Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > REPOST - Parent List Data Item!

Reply
Thread Tools

REPOST - Parent List Data Item!

 
 
Adam Knight
Guest
Posts: n/a
 
      11-21-2005
Hi all,

I am really trying to find a solution to this problem.

I have a pair of nested data lists.

I want to retrieve a current value out of the parent lists DataItem object
(?.?.Container.DataItem) , inside a template within the child list.
This happens while the page is databinding, obviously using
Container.DataItem for all other page values.

Can anyone help me with this?

No item is being selected in the parent list, so the selected index won't
achieve what i am after.

Cheers,
Adam


 
Reply With Quote
 
 
 
 
Adam Knight
Guest
Posts: n/a
 
      11-21-2005
Hi all,

This is one solution i have come up with..

It appears a little clumsy to me though???

<%#
CType(Container.Parent.Parent.Parent.Parent,DataLi stItem).DataItem("standard_id")
%>
If retrieves the CURRENT list item of the parent list..and accesses the
DataItem Object.

Cheers,
Adam

"Adam Knight" <> wrote in message
news:...
> Hi all,
>
> I am really trying to find a solution to this problem.
>
> I have a pair of nested data lists.
>
> I want to retrieve a current value out of the parent lists DataItem object
> (?.?.Container.DataItem) , inside a template within the child list.
> This happens while the page is databinding, obviously using
> Container.DataItem for all other page values.
>
> Can anyone help me with this?
>
> No item is being selected in the parent list, so the selected index won't
> achieve what i am after.
>
> Cheers,
> Adam
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
If a class Child inherits from Parent, how to implementChild.some_method if Parent.some_method() returns Parent instance ? metal Python 8 10-30-2009 10:31 AM
Page load of the parent page called twice when a modal dialog is opened from a button click of the user control on the parent page Samy ASP .Net 2 08-15-2005 03:30 PM
Parent - Child back to parent javascript thingybob mark ASP .Net 1 03-10-2005 02:20 PM
What does sender.Parent.Parent.Cells() reference? Frustrating... Roy ASP .Net 2 02-11-2005 09:00 PM
Getting a page to refresh the parent, even when not loaded from the parent? Bill S. Javascript 2 05-08-2004 04:56 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57