将XML从服务器端发送到CLient端

时间:2016-10-21 02:13:02

标签: java c# jquery vb.net

任何人帮助我,..

strFileName =" C:\ xmlTest.xml"
 昏暗的dsEqp作为新的DataSet
 dsEqp.Tables.Add(" TEST")
 dsEqp.WriteXml(strFileName,XmlWriteMode.WriteSchema)

如何将XML文件从服务器发送到文件夹客户端计算机?

请帮助

这里是我的代码

    Dim strActualProdID As String
    strActualProdID = Trim(Me.lblactualprodid.Text) & "_status.xml"
    Dim bl_other As New BusinessLayer.clsPCMonthlyProductionPlan
    Dim strFileName As String
    strFileName = bl_other.ExportFolder(Me.Session("authstate")) & "\" & strActualProdID

    tabActual.Tabs.FromKeyTab("tabstatus").ContentPane.UserControlUrl = ".\ctlPC_ActualEqpEvent.ascx"
    ctrl_ProdStatus = CType(Me.tabActual.Tabs.FromKeyTab("tabstatus").ContentPane.UserControl, ctlPC_ActualEqpEvent)

    Dim dsEqpStatus As DataSet = ctrl_ProdStatus.getTransAddData()
    dsEqpStatus.WriteXml(strFileName, XmlWriteMode.WriteSchema)


    Dim objStream As New System.IO.MemoryStream()
    dsEqpStatus.WriteXml(objStream, XmlWriteMode.WriteSchema)
    Dim client As New WebClient
    client.DownloadFile(strFileName, "C:\CMOSDIR\" & strActualProdID)
    client.Dispose()

0 个答案:

没有答案