GridView XmlDataSource

B

Ben Schumacher

On a webform I have a GridView control and an XmlDataSource control. I set
the datacontrolid of the gridview control to the id of the xmldatasource
control and everything looks fine. The xml looks somthing like below ...

<FolderReferences>
<FolderReference type="Number" value="12345"/>
</FolderReferences>

I also have two text boxes and a button on the webform so that the user can
add additional folder references to the grid. They simply type the values
in the two text boxes and click the add button. On the postback i build
another <FolderReference> node and append it to any existing reference in
the xml and ther set the xmldatasource.data property to the newly created
xml. Unfortunatly i never see the newly added row. I know the xml is
right. I can see the new xml structure with the two <FolderReference>
nodes, but I only see what was originally in the gridview control. It won't
re-bind itself to my new structure that is provide.

Any suggestions?

Ben
 
C

CaffieneRush

I wonder if the xmldatasource is caching. Test by turning it off and
running your scenario again.
myXds.EnableCaching = False

Regards.
Andy

ps. I never thought about using xmldatasource with gridview.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,902
Latest member
Elena68X5

Latest Threads

Top