【发布时间】:2013-04-20 12:34:30
【问题描述】:
我的 global.asax 文件。好像
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.SessionState;
namespace xxxx
{
public class Global : System.Web.HttpApplication
{
protected void Application_Start(object sender, EventArgs e)
{
}
}
}
但是当我查看其他 global.asax 文件时,似乎
<%@ Application Language="C#" %>
<%@ Import Namespace="System" %>
<%@ Import Namespace="System.Diagnostics" %>
<script runat="server">
void Application_Start(object sender, EventArgs e)
{
// Code that runs on application startup
}
</script>
为什么我的 global.asax 文件与他们不同?我使用 4.0 框架。当我尝试路由时,我的项目看不到我的路由规则。
【问题讨论】:
标签: asp.net url-routing global-asax