VBScript / ASP-Classic“停止”语句不会破坏调试器

时间:2023-01-05 01:34:39

I've used to put a "stop" statement in my VBScript/ASP-Classic code to break into debugger (Microsoft Script Editor, that comes with Microsoft Office).

我曾经在我的VBScript / ASP-Classic代码中放入一个“停止”语句来打入调试器(微软脚本编辑器,Microsoft Office附带)。

But now it isn't breaking anymore. The "stop" is ignored and nothing happpens.

但现在它不再破坏了。 “停止”被忽略,没有任何好处。

The server-side debugging flag is already enabled in IIS

IIS中已启用服务器端调试标志

How to solve this?

怎么解决这个?


Sample Code, hello.asp

示例代码,hello.asp

stop 
Response.Write "Hello W."

3 个解决方案

#1


Try this instead of Stop:

试试这个而不是停止:

Dim I
I = 1 / 0

#2


Are you running VBScript in an Office app? Wouldn't that be VBA?

你在Office应用程序中运行VBScript吗?那不是VBA吗?

For VBScript debugging you need to enable that with the /d switch on with wscript or cscript when running the vbs file:-

对于VBScript调试,您需要在运行vbs文件时使用/ d开关启用wscript或cscript: -

 wscript /d c:\myfolder\myscript.vbs

Edit: Did I miss the ASP-Classic bit?

编辑:我错过了ASP-Classic位吗?

In this case you have turned off debugging in the application configuration. In IIS6 open properties on the ASP application, select Home Directory tab, click "Configuration..." in the Application Settings section. Select the Debugging tab, select the debugging flags.

在这种情况下,您已在应用程序配置中关闭调试。在ASP6应用程序的IIS6打开属性中,选择“主目录”选项卡,单击“应用程序设置”部分中的“配置...”。选择Debugging选项卡,选择调试标志。

#3


It may be a problem with the Registry - See http://support.microsoft.com/kb/252895

这可能是注册表的问题 - 请参阅http://support.microsoft.com/kb/252895

#1


Try this instead of Stop:

试试这个而不是停止:

Dim I
I = 1 / 0

#2


Are you running VBScript in an Office app? Wouldn't that be VBA?

你在Office应用程序中运行VBScript吗?那不是VBA吗?

For VBScript debugging you need to enable that with the /d switch on with wscript or cscript when running the vbs file:-

对于VBScript调试,您需要在运行vbs文件时使用/ d开关启用wscript或cscript: -

 wscript /d c:\myfolder\myscript.vbs

Edit: Did I miss the ASP-Classic bit?

编辑:我错过了ASP-Classic位吗?

In this case you have turned off debugging in the application configuration. In IIS6 open properties on the ASP application, select Home Directory tab, click "Configuration..." in the Application Settings section. Select the Debugging tab, select the debugging flags.

在这种情况下,您已在应用程序配置中关闭调试。在ASP6应用程序的IIS6打开属性中,选择“主目录”选项卡,单击“应用程序设置”部分中的“配置...”。选择Debugging选项卡,选择调试标志。

#3


It may be a problem with the Registry - See http://support.microsoft.com/kb/252895

这可能是注册表的问题 - 请参阅http://support.microsoft.com/kb/252895