原文:
I got this working. The trick (as I found in another post) was to hit Continue andleave the debugger running and then execute the template again. This got me source and the ability to find the erring line. So here is what I did:
1) Add \"<%#DEBUG%><%\" (minus the quotes) to the first line + System.Diagnostics.Debugger.Launch(); to the Render() method.
2) Execute the template. Chose VS2005 as debugger. It comes up without source (disassembly only). Hit F5 to continue.
3) Switch back to MyGeneration and Execute the template again. This time the debugger has source.
So it is a workable workaround, but does anyone know if there are plans to fix this issue in the near future?
Lars
分为以下步骤:
1.在模板方法Render() 中加入System.Diagnostics.Debugger.Launch();
2.执行模板一次,会调用vs进行调试.注意这时并不会带原码.
3.再执行模板一次.则会进入代码调试阶段.