为什么不存在变量(ASPX)?

发布于 2025-01-26 13:38:47 字数 274 浏览 2 评论 0原文

这是ASP.NET项目(.NET 4.7.2)中的.aspx文件(Web form)。

本地变量mytestString在第3行中定义。为什么说它在第14行中不存在?

This is a .aspx file (web form) in an asp.net project (.net 4.7.2).

The local variable myTestString is defined at line 3. Why does it say that it doesn't exist at line 14?

enter image description here

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

缪败 2025-02-02 13:38:47

它不起作用,因为该变量被用runat =“ server”在元素内部使用。

It doesn't work because the variable is being used inside an element with runat="server".

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文