Hello all,
I wrote an app using VS2003 which persists all its data (not that much) to XML locally on the harddrive. I did this by creating an XSD schema which described my data and can then be created as a typed dataset ie,
My typed dataset can then read in my stored XML:
And write it back out after ive messed with it via datagrids and binding:
Now, ive moved onto VS2005 and im having real trouble recreating the mechanism. I can define my schema ok, and then VS2005 starts treating it as a 'DataSet' file, which is fine - but my 'DataSet' has no methods!! When I look in the .vb code file for the dataset it is empty - in good old 2003, I had a a load of studio generated code..
Has anyone else had this problem / know where im going wrong??
Thanks
mafro
I wrote an app using VS2003 which persists all its data (not that much) to XML locally on the harddrive. I did this by creating an XSD schema which described my data and can then be created as a typed dataset ie,
VB.NET:
<xs:element name="favs">
<xs:complexType>
<xs:sequence>
<xs:element name="name" type="xs:string" />
<xs:element name="url" type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:element>
VB.NET:
reader = New Xml.XmlTextReader(New StreamReader(path))
dsTypedDataSet = New TypedDataSet()
dsTypedDataSet.ReadXml(reader)
VB.NET:
dsTypedDataSet.WriteXml(path)
Has anyone else had this problem / know where im going wrong??
Thanks
mafro
Last edited: