vb中如何读写文本文件?给个简单的例子 如题 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 set fso=createobject("scripting.filesystemobject")xmlstr="<?xml version='1.0'?>" xmlstr="<info>" xmlstr=xmlstr&"<receiverinfo>" xmlstr=xmlstr&"<name>" xmlstr=xmlstr&rs1("name") xmlstr=xmlstr&"</name>" xmlstr=xmlstr&"<province>" xmlstr=xmlstr&rs1("province") xmlstr=xmlstr&"</province>" xmlstr=xmlstr&"<city>" xmlstr=xmlstr&rs1("city") xmlstr=xmlstr&"</city>" xmlstr=xmlstr&"<address>" xmlstr=xmlstr&rs1("address") xmlstr=xmlstr&"</address>" xmlstr=xmlstr&"<postcode>" xmlstr=xmlstr&rs1("postcode") xmlstr=xmlstr&"</postcode>" xmlstr=xmlstr&"<telephonenum>" xmlstr=xmlstr&rs1("telephonenum") xmlstr=xmlstr&"</telephonenum>" xmlstr=xmlstr&"<pricesum>" xmlstr=xmlstr&rs1("pricesum") xmlstr=xmlstr&"</pricesum>" xmlstr=xmlstr&"<ordercode>" xmlstr=xmlstr&rs1("ordercode") xmlstr=xmlstr&"</ordercode>" rs1.close set rs1=nothing xmlstr=xmlstr&"</receiverinfo>" xmlstr=xmlstr&"<orderpic>" while not rs.eof sourcename=app.path(name) sourcename=sourcename&"\"&"photos"&"\"&rs("picname") fso.copyfile sourcename, desname xmlstr=xmlstr&"<picinfo>" xmlstr=xmlstr&"<picname>" xmlstr=xmlstr&rs("picname") xmlstr=xmlstr&"</picname>" xmlstr=xmlstr&"<picnum>" xmlstr=xmlstr&rs("picnum") xmlstr=xmlstr&"</picnum>" xmlstr=xmlstr&"<flushsize>" xmlstr=xmlstr&rs("flushsize") xmlstr=xmlstr&"</flushsize>" xmlstr=xmlstr&"</picinfo>" 'response.write sourcename&"<br>" rs.movenext wend xmlstr=xmlstr&"</orderpic>" xmlstr=xmlstr&"</info>" desname=desname&ordercode&".xml" set fsoorder=fso.CreateTextFile(desname, true, false) fsoorder.Write xmlstr fsoorder.close 如何在webbrowser的DownloadCompleted事件中查找替换webbrowser.Document.InnerHTML中的内容 求组,汉字字节问题? VB runtime运行库的问题 急!!!!!!!!! 弱弱的问一下 关于VBframe控件.. 请教存储过程问题(100) 关于textbox 有没有谁对 MMS 彩信协议、PPP 协议熟悉的同学? 有谁知道如何获得CPU的系列号吗? “势不两立” 请问高手几个菜鸟问题 怎么将窗体上面的焦点释放 ? 数据库模糊查询问题
xmlstr="<?xml version='1.0'?>"
xmlstr="<info>"
xmlstr=xmlstr&"<receiverinfo>"
xmlstr=xmlstr&"<name>"
xmlstr=xmlstr&rs1("name")
xmlstr=xmlstr&"</name>"
xmlstr=xmlstr&"<province>"
xmlstr=xmlstr&rs1("province")
xmlstr=xmlstr&"</province>"
xmlstr=xmlstr&"<city>"
xmlstr=xmlstr&rs1("city")
xmlstr=xmlstr&"</city>"
xmlstr=xmlstr&"<address>"
xmlstr=xmlstr&rs1("address")
xmlstr=xmlstr&"</address>"
xmlstr=xmlstr&"<postcode>"
xmlstr=xmlstr&rs1("postcode")
xmlstr=xmlstr&"</postcode>"
xmlstr=xmlstr&"<telephonenum>"
xmlstr=xmlstr&rs1("telephonenum")
xmlstr=xmlstr&"</telephonenum>"
xmlstr=xmlstr&"<pricesum>"
xmlstr=xmlstr&rs1("pricesum")
xmlstr=xmlstr&"</pricesum>"
xmlstr=xmlstr&"<ordercode>"
xmlstr=xmlstr&rs1("ordercode")
xmlstr=xmlstr&"</ordercode>"
rs1.close
set rs1=nothing
xmlstr=xmlstr&"</receiverinfo>"
xmlstr=xmlstr&"<orderpic>"
while not rs.eof
sourcename=app.path(name)
sourcename=sourcename&"\"&"photos"&"\"&rs("picname")
fso.copyfile sourcename, desname
xmlstr=xmlstr&"<picinfo>"
xmlstr=xmlstr&"<picname>"
xmlstr=xmlstr&rs("picname")
xmlstr=xmlstr&"</picname>"
xmlstr=xmlstr&"<picnum>"
xmlstr=xmlstr&rs("picnum")
xmlstr=xmlstr&"</picnum>"
xmlstr=xmlstr&"<flushsize>"
xmlstr=xmlstr&rs("flushsize")
xmlstr=xmlstr&"</flushsize>"
xmlstr=xmlstr&"</picinfo>"
'response.write sourcename&"<br>"
rs.movenext
wend
xmlstr=xmlstr&"</orderpic>"
xmlstr=xmlstr&"</info>"
desname=desname&ordercode&".xml"
set fsoorder=fso.CreateTextFile(desname, true, false)
fsoorder.Write xmlstr
fsoorder.close