How to dispaly attributes of xml nested repeater..(if XML not followed hierarchical structure)
-
Hello every one I am facing a problem to display attribute of parent node and corresponding child nodes.Suppose I have to display Label attributes of all . There can be multiple inside parent node . In this case I have to display Label 'rediffHomePage' and 'rediffHomePage1' of both node. There is no issue to diplay these two Label. I done this by taking a repeater control. But problem arrises when I have to display corresponding Label of 'FieldsToSupport/FieldToSupport' of .. For example on click an Item like rediffHomePage from a repeater It should display like 'HotJobs' and 'Game'. How can I display Label of corresponding FieldsToSupport/FieldToSupport on click on corresponding Label of .. Should I take Repeater inside Repeater or I Repeater inside DataList. following is the structure of XML file -------------------------------------------------------------------- 199d1dfd-63ca-4271-b234-77da0f579e0e ... 1 ... HotJobs ... ... Game ... rediffHomePage e62abc49-efc7-4a5d-908f-33f2f4df070b ... 2 .. Images .. ... Air Tickets ... rediffHomePage1 -------------------------------------------------------------------- and following is my .cs file -------------------------------------------------------------------- <%@ Page Languag
-
Hello every one I am facing a problem to display attribute of parent node and corresponding child nodes.Suppose I have to display Label attributes of all . There can be multiple inside parent node . In this case I have to display Label 'rediffHomePage' and 'rediffHomePage1' of both node. There is no issue to diplay these two Label. I done this by taking a repeater control. But problem arrises when I have to display corresponding Label of 'FieldsToSupport/FieldToSupport' of .. For example on click an Item like rediffHomePage from a repeater It should display like 'HotJobs' and 'Game'. How can I display Label of corresponding FieldsToSupport/FieldToSupport on click on corresponding Label of .. Should I take Repeater inside Repeater or I Repeater inside DataList. following is the structure of XML file -------------------------------------------------------------------- 199d1dfd-63ca-4271-b234-77da0f579e0e ... 1 ... HotJobs ... ... Game ... rediffHomePage e62abc49-efc7-4a5d-908f-33f2f4df070b ... 2 .. Images .. ... Air Tickets ... rediffHomePage1 -------------------------------------------------------------------- and following is my .cs file -------------------------------------------------------------------- <%@ Page Languag
You should look at using nested Repeater controls[^] to solve your problem. BTW, why are you mixing your server-side code and markup in the same file? You should really consider splitting the server-side code out into a code-behind file for the sake of maintainability. I haven't seen code mixed like this since the bad old days of ASP...
Paul Marfleet "No, his mind is not for rent To any God or government" Tom Sawyer - Rush
-
You should look at using nested Repeater controls[^] to solve your problem. BTW, why are you mixing your server-side code and markup in the same file? You should really consider splitting the server-side code out into a code-behind file for the sake of maintainability. I haven't seen code mixed like this since the bad old days of ASP...
Paul Marfleet "No, his mind is not for rent To any God or government" Tom Sawyer - Rush
Sir, can you give me any solution to how can i do this. I will very thankful to you..
-
Sir, can you give me any solution to how can i do this. I will very thankful to you..
Have you looked at the examples I suggested? Have you attempted to solve the problem yourself? Seriously, if you can't be bothered to help yourself then I can't give you any further advice.
Paul Marfleet "No, his mind is not for rent To any God or government" Tom Sawyer - Rush