Asp.net Forum

Ask Question   UnAnswered
Home » Forum » Asp.net       RSS Feeds

before page_load

  Asked By: Maria    Date: Oct 29    Category: Asp.net    Views: 579

i want to grab some cookie value before page_load function in some control code
behind page:
is it possible ?


int userID = Request.cookies["cookName"];

private void Page_Load(object sender, System.EventArgs e)



error : Y:\AdminTools\netTools\ascx\header.ascx.cs(26): A field initializer
cannot reference the nonstatic field, method, or property



1 Answer Found

Answer #1    Answered By: Rafael Thompson     Answered On: Oct 29

Why do you want to get the cookie value before the page  load.

Didn't find what you were looking for? Find more on before page_load Or get search suggestion and latest updates.