Ooops... yeah you're right. While I was testing I was reading the data from disk rather than reading the XML...
+++ Rick ---
>>I've just posted a new article on the West Wind site:
>>
.NET Interop for Visual FoxPro>>
http://www.west-wind.com/presentations/VfpDotNetInterop/vfpDotNetInterop.htm>
>
>Hi, Rick.
>
>Nice article. Thanks!
>
>
>Look, I think there´s an error in listing 23.4:
>
>
>FUNCTION XMLDataSet(lcXML as String,lcCursor as String) as String
>
>oXML = CREATEOBJECT("wwXML")
>CREATE CURSOR Temp (au_id c(10), au_lname c(15), Contract L, PK I)
>XML.DataSetXMLToCursor(FILETOSTR("d:\temp\authors.xml"),"temp","authors")
>
>*** Just echo the data back as an HTML string
>RETURN this.ShowCursor()
>
>
>Instead of take a file from your disk, you must take the lcXML parameter, don´t you?