I have been trying to create a hit counter as follows,
create a global.asax page - inside it i have created an Application as below
void Application_Start(object sender, EventArgs e)
// Code that runs on application startup
Application["hitCounter"] = 0;
then in my code behind page of my hits page i have this
protectedvoid Page_Load(object sender, EventArgs e)
Application["hitCounter"] = Application["hitCounter" + 1];
Label1.Text = (Application["hitCounter"]);}
And the error is cannot convert type object to string.
I have seen a video of how to do this using vb instead of c# and it works fine. Can anyone point me in the correct direction of the syntax for c#.