问题描述
在 Visual Studio 中,我在 ascx 中获取 ModuleID 时总是出现以下错误,但模块编译成功。任何想法如何解决这些问题?
这是我注册 ascx 的方式:
<%@ Control Language="vb" AutoEventWireup="true" CodeBehind="View.ascx.vb" Inherits="Christoc.Modules.babyList.View" %>
解决方法
尝试使用此代码访问 ascx 文件中的 Moduleid
<%= ModuleId %>