Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8443095
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T09:02:32+00:00 2026-06-10T09:02:32+00:00

I’m very new to asp.net, but I found setting up a scaffolded website for

  • 0

I’m very new to asp.net, but I found setting up a scaffolded website for an existing database is super simple. I have it up and running.

Making things work the way I want is a bit more tricky.. I have a Customer table with a one-to-many relationship with the ContactMoment table. By default the detail view of Customer show a link to view the ContactMoments (which is defined in the FieldTemplate called Children by default). What I would like is to include a ListView of all the ContactMoments.

I tried the following:

<asp:ListView runat="server" ID="DynamicControl2" DataMember="ContactMoment" />

This does not work. I probably need to use the DataSourceID, but I have no idea how te retrieve that from the current entity. Could someone point me in the right direction? Thanks 🙂

Update: I just found Dynamic Data Extensions which lists the following interesting bit. (unfortunately the project seems abandoned..)

  1. ChildrenList – Provides a way to show child tables, works in conjunction with the new Edit and Details page templates.
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T09:02:34+00:00Added an answer on June 10, 2026 at 9:02 am

    You need to add an extra datasource and Listview Control to get the result you want..

    I haven’t tried this Code but it should work… make changes to Entity names according to your actual Names..

    <asp:EntityDataSource ID="ContactMomentDataSource" runat="server"  
            ContextTypeName="YourEntities" EnableFlattening="False"  
            EntitySetName="ContactMoment"  
            Where="@CustomerID IN (SELECT VALUE Customer.CustomerID FROM it.Customer  AS Customer)"> 
            <WhereParameters> 
                <asp:ControlParameter ControlID="YourDetailView" Type="Int32" Name="CustomerID" PropertyName="SelectedValue" /> 
            </WhereParameters> 
        </asp:EntityDataSource>
    
    <asp:ListView ID="ContactMomentListView" runat="server"  
            DataSourceID="ContactMomentDataSource" 
            AllowSorting="True" AutoGenerateColumns="False" 
            SelectedRowStyle-BackColor="LightGray"  
            DataKeyNames="ContactMomentID"> 
            </asp:ListView>
    

    Now you just need to add Column you want to display in Listview’s markup..

    Hope this helps…

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have just tried to save a simple *.rtf file with some websites and
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I have a French site that I want to parse, but am running into
This could be a duplicate question, but I have no idea what search terms
Seemingly simple, but I cannot find anything relevant on the web. What is the
I have a reasonable size flat file database of text documents mostly saved in
I have a view passing on information from a database: def serve_article(request, id): served_article
I have a .ini file as follows: [playlist] numberofentries=2 File1=http://87.230.82.17:80 Title1=(#1 - 365/1400) Example
I have a jquery bug and I've been looking for hours now, I can't
link Im having trouble converting the html entites into html characters, (&# 8217;) i

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.