locked
How to get the binding data from element control RRS feed

  • Question

  • I followed the guide to use data template with an array from here: http://msdn.microsoft.com/en-us/library/windows/apps/hh700356.aspx

    The renderElement is bound with data people[selected--] using this:

    templateElement.winControl.render(people[selected--])
                .done(function (result) {
                     renderElement.appendChild(result);
                }); 

    Now I have the element control of the renderElement , which has been bound data, how could i get the bound data?

    Please help. Thanks!

    Monday, September 2, 2013 3:14 AM

All replies

  • Hi Forzas,

    Switch back to Visual Studio while debugging the app, you can find the element can be listed by DOM structure and you could get what you need by querying for DOM.

    Hope this will help you and Best regards,

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Tuesday, September 3, 2013 7:47 AM
    Moderator
  • Hi Jamles, 

    I am not sure what you mean, i have the DOM element now, i want to get the data bound to this DOM.

    Thanks.

    Friday, September 6, 2013 5:32 AM
  • Hi Forzas,

    Bound to this DOM? You mean the first and the last element of the DOM? Or do you mean by "Binding"? I'm confusing with your question, could you mind explain me with a scenario.

    --James


    <THE CONTENT IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, WHETHER EXPRESS OR IMPLIED>
    Thanks
    MSDN Community Support

    Please remember to "Mark as Answer" the responses that resolved your issue. It is a common way to recognize those who have helped you, and makes it easier for other visitors to find the resolution later.

    Monday, September 9, 2013 6:31 AM
    Moderator
  • Hi Forzas,

    Are you trying to get the bound data to show up in the app? What are you trying to do? Please let me know and I will be able to help you out. Also, have you tried using Blend for HTML to do data binding?

    http://blogs.msdn.com/b/visualstudio/archive/2013/09/03/what-s-new-for-html-developers-in-blend-for-visual-studio-2013-preview.aspx


    - Avani Chandrasekaran

    Tuesday, September 24, 2013 11:36 PM