With Tables("订单")
If .current IsNot Nothing Then
Dim jo As new XObject
For Each c As Col In Tables("订单").cols
jo(c.name)=.current(c.name).Tostring()
Next
Dim fl As String=ProjectPath & "xml\\" & .current("单号") & "\\" & .current("单号") & ".xml"
If FileSys.FileExists(fl) Then
FileSys.DeleteFile(fl)
End If
Dim str As String="<?xml version=""1.0"" encoding=""UTF-8"" standal"?> " & "<!--Web portal To AES: the XML Document Definition: Viewing Order
Version 1 " & "by foxtable " & Date.now & "-->"
FileSys.WriteAllText(fl,str & jo.Toxml, True, Encoding.Default)
End If
End With