private static string Sub0_Method(HttpContext context)
{
//在页面中使用Substitution,怎样在静态方法中获取Profile引用? } <asp:Substitution ID="sub0" runat="server" MethodName="Sub0_Method" />
{
//在页面中使用Substitution,怎样在静态方法中获取Profile引用? } <asp:Substitution ID="sub0" runat="server" MethodName="Sub0_Method" />
{
name.****;
}
public delegate string HttpResponseSubstitutionCallback (HttpContext context)你给的答案是 : private static string Sub0_Method(Substitution name),根本就是错的,你自己回答别人的问题有没有试过呀,真不知道你的星是怎么混的.悬赏:答对或思路对得200分!
根据这点,那我们先定义一个静态成员,且设置其属性访问器
在页面装载事件中那我们直接通过 类.静态成员,对其进行赋值操作(Profile引用)!
那样在private static string Sub0_Method(HttpContext context){
}中就能正确引用了!