Hi,
I am afraid that it is impossible what you try to accomplish with current implementation
AjaxResult and AjaxStoreResult always return JSON object therefore the XML will be accessable as field of JsonReader. You can get whole XML as string but you need parse XML manually (store will not parse that XML because it is part of JSON object). Even if you able parse that XML you have to create records and add it to the store. It is lot of code in javascript. Therefore I recomend to return simple server side collection (for example, List<MyType>)
You can easly convert XML to required collection. For example, see how we convert XML to the required collection in the demo application Ext.Net.MVC
public AjaxStoreResult GetHomeSchema()
{
XElement document = XElement.Load(Server.MapPath("~/resources/images/HomeSchema.xml"));
var defaultIcon = document.Attribute("defaultIcon") != null ? document.Attribute("defaultIcon").Value : "";
var query = from g in document.Elements("group")
select new
{
Title = g.Attribute("title") != null ? g.Attribute("title").Value : "",
Items = (from i in g.Elements("item")
select new
{
Title = i.Element("title") != null ? i.Element("title").Value : "",
Icon = i.Element("item-icon") != null ? i.Element("item-icon").Value : defaultIcon,
Accordion = i.Element("accordion-item") != null ? i.Element("accordion-item").Value : "",
MenuItem = i.Element("menu-item") != null ? i.Element("menu-item").Value : ""
}
)
};
return new AjaxStoreResult(query);
}
Store
<ext:Store runat="server" ID="Store1" AutoLoad="true">
<Proxy>
<ext:HttpProxy Url="/Data/GetHomeSchema/" />
</Proxy>
<Reader>
<ext:JsonReader Root="data">
<Fields>
<ext:RecordField Name="Title" />
<ext:RecordField Name="Items" />
</Fields>
</ext:JsonReader>
</Reader>
</ext:Store>
P.S. XmlReader can be using if you return pure XML response with type "text/xml" (like classic WebService response)