On Tue, Jun 22, 2010 at 5:14 AM, sunil <[email protected]> wrote:
> hi its simple
>
> create the object of dataset
> fill it with the required data
> and write dataset.writeXML("folder path")
>
> the code is as simple
>
> ds = New DataSet
> dataadapter.Fill(ds, "keyword")
> ds.WriteXml("D:\\keywords.xml")
>
---------------
Not going to work when you have data collections that are collections
of collections.
[DataContract(Name = "BINumber", Namespace =
"http:/schemas.cimsgts.com/SC/AH/v1.0")]
[Serializable]
public class BINumber
{
[DataMember(Name = "IndictmentNumber", Order = 1, IsRequired = true)]
public String indictmentNumber
{ set; get; }
[DataMember(Name = "BookingNumber", Order = 1, IsRequired = true)]
public int bookingNumber
{ set; get; }
[DataMember(Name = "DaysInJail", Order = 1, IsRequired = true)]
public int DaysInJail
{ set; get; }
[DataMember(Name = "Sentence", Order = 1, IsRequired = true)]
public List<Sentence> Dispositions
{ set; get; }
[DataMember(Name = "ChargeLine", Order = 1, IsRequired = true)]
public List<ChargeLine> ChargeLines
{ set; get; }
}
I have data in objects like this all the time and you just cant say
.Write.toXML()
Have not used a DataSet in 6 years I think/hope. You can't share
DataSets with anything outside of VS and I have to pass munged data
all the time.
--
Stephen Russell
Sr. Production Systems Programmer
CIMSgts
901.246-0159 cell