来帮忙 顺便拿分
Dim script As String = " "
script += " <script type= 'text/javascript '> "
script += "function create_txt(){ "
script += "var fso,f; "
script += "fso = new window.ActiveXObject( 'Scripting.FileSystemObject '); "
script += "f = fso.CreateTextFile( 'c:\\testfile.txt ', true); "
script += "f.WriteLine( 'xxxxxxxxxxxxxxxxxx123 '); "
script += "f.Close(); "
script += "} "
script += "create_txt(); "
script += " </script> "
Dim key As String = Me.Session.SessionID & My.Computer.Clock.TickCount
Page.ClientScript.RegisterStartupScript(Page.GetType, key, script)
上面那段javascript代码为什么在aspx网页中会发生 "Automation伺服程式无法产生物件 "错误,而在html网页中可以正常运行 该如何解决 谢谢
------解决方案--------------------安全问题
把你的站点设为信任 站点就可以了
------解决方案--------------------JF