Oh, delete the line with 'ListBox1.DataSource = DS' in it, I forgot to!
-----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Hona, David S Sent: Wednesday, May 14, 2008 2:32 PM To: u2-users@listserver.u2ug.org Subject: RE: [U2] UniObjects.NET: populating ListBox from XML Clif, Try something like this... Cmd = uvSession.CreateUniXML Cmd.GenerateXML("SORT CUSTOMER COMPANY ID.SUP") DS = Cmd.GetDataSet ListBox1.DataSource = DS With ListBox1 .DataSource = DS.Tables(0) .DisplayMember = "COMPANY" .ValueMember = "CUSTOMER" End With Regards, David -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Clifton Oliver Sent: Wednesday, May 14, 2008 9:05 AM To: u2-users@listserver.u2ug.org Subject: [U2] UniObjects.NET: populating ListBox from XML Having been successful last week at populating a GridDataView control using .GenerateXML, we naively thought using XML to populate a ListBox would be just as straightforward. Using the same code pattern, we've tried Cmd = uvSession.CreateUniXML Cmd.GenerateXML("SORT CUSTOMER COMPANY ID.SUP") DS = Cmd.GetDataSet ListBox1.DataSource = DS ListBox1.DisplayMember = "CUSTOMER" ListBox1.Refresh() gives us one line in the ListBox that reads System.Data.DataViewManagerListItemTypeDescriptor Are we missing something from this incantation, or is this not a valid way to try to populate a ListBox? (Yeah, I guess ComboBoxes are next.) Thanks in advance for any help, examples, or RTM references! Regards, Clif ------- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ ------- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/ ------- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/