pivot-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Greg Brown <gk_br...@verizon.net>
Subject Re: TreeView issue on Element Selection
Date Wed, 13 Apr 2011 13:16:43 GMT
Any chance you could provide a simple working example using the data you generate below to
help diagnose the problem?

On Apr 12, 2011, at 9:39 PM, Thomas Grimaud wrote:

> Hi,
> 
> Using the demo "XML Viewer", I did my own parser in order to pick up only  informations
that I need (as I'm working with a structured xsd file I don't want to display all the content
of the file)
> Basically for the file I'm working on, the result after the parsing is the same as that
:
> 
> public static Element hardBuildTree(){
> 		Element ret = new Element("invoice");
> 		
> 		Element header = new Element("header");
> 		Element items = new Element("items");
> 		Element item = new Element("item");
> 		items.add(item);
> 		Element total = new Element("total");
> 		
> 		header.add(new Element("document_type_desc_1"));
> 		header.add(new Element("document_type_desc_2"));
> 		header.add(new Element("company_name"));
> 		header.add(new Element("company_address_1"));
> 		header.add(new Element("company_address_2"));
> 		header.add(new Element("company_address_3"));
> 		header.add(new Element("abn"));
> 		header.add(new Element("acn"));
> 		header.add(new Element("document_number"));
> 		header.add(new Element("document_date"));
> 		header.add(new Element("customer_number"));
> 		header.add(new Element("customer_name"));
> 		header.add(new Element("customer_address_1"));
> 		header.add(new Element("customer_address_2"));
> 		header.add(new Element("customer_address_3"));
> 		header.add(new Element("delivery_name"));
> 		header.add(new Element("delivery_address_1"));
> 		header.add(new Element("delivery_address_2"));
> 		header.add(new Element("delivery_address_3"));
> 		header.add(new Element("location_number"));
> 		header.add(new Element("supplier_number"));
> 		header.add(new Element("reference"));
> 		
> 		item.add(new Element("item_code"));
> 		item.add(new Element("line_number"));
> 		item.add(new Element("item_code"));
> 		item.add(new Element("item_desc_1"));
> 		item.add(new Element("item_desc_2"));
> 		item.add(new Element("item_reference"));
> 		item.add(new Element("item_quantity"));
> 		item.add(new Element("item_unit"));
> 		item.add(new Element("item_unit_cost"));
> 		item.add(new Element("item_extended_amount"));
> 		item.add(new Element("item_amount"));
> 		item.add(new Element("item_tax_code"));
> 		item.add(new Element("item_tax_amount"));
> 		item.add(new Element("item_discount_percent"));
> 		item.add(new Element("item_discount_amount"));
> 		
> 		total.add(new Element("total_amount"));
> 		total.add(new Element("total_extended_amount"));
> 		total.add(new Element("total_tax_amount"));
> 		
> 		ret.add(header);
> 		ret.add(items);
> 		ret.add(total);
> 		
> 		return ret;
> 	}
> 
> 
> I'm using the same Node Renderer as the demo, and the display is working fine.
> 
> My issue is that most of my elements are not selectable: I can browse the tree until,
for example, all the elements in the item branch but there i can only select the first element
(item_code), but all the other elements are not selectable.
> If I use directly, like for the demo, the result of the function readObject of the XmlSerialiser
everything is working fine, but as soon as I try to manipulate the data in order to build
my own list it doesn't work.
> So I guess that my Element tree is not build properly but I can't find what I'm doing
wrong.
> 
> 
> Could you please help?
> 
> Regards,
> 
> Thomas


Mime
View raw message