Click here to Skip to main content
15,889,595 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: Session or Viewstate Pin
Abhijit Jana25-Dec-08 2:07
professionalAbhijit Jana25-Dec-08 2:07 
GeneralRe: Session or Viewstate Pin
Nishant Singh25-Dec-08 2:19
Nishant Singh25-Dec-08 2:19 
AnswerRe: Session or Viewstate Pin
Christian Graus25-Dec-08 14:50
protectorChristian Graus25-Dec-08 14:50 
AnswerRe: Session or Viewstate Pin
Aman Bhullar25-Dec-08 18:15
Aman Bhullar25-Dec-08 18:15 
QuestionForm Authentication using as.net 2.0 Pin
sbua24-Dec-08 23:37
sbua24-Dec-08 23:37 
AnswerRe: Form Authentication using as.net 2.0 Pin
Abhijit Jana24-Dec-08 23:41
professionalAbhijit Jana24-Dec-08 23:41 
Questionhow to get the value Pin
R111924-Dec-08 22:17
R111924-Dec-08 22:17 
AnswerRe: how to get the value Pin
Abhijit Jana24-Dec-08 22:33
professionalAbhijit Jana24-Dec-08 22:33 
Its seems , you didn't understand your last answer that what other people given. Sleepy | :zzz:
just do it using View State.

protected void Page_Load(object sender, EventArgs e)<br />
{<br />
if(ViewState["TestVal"] !=null )<br />
<br />
   {<br />
    //Do Something<br />
   }<br />
   else<br />
   {<br />
    //Do Something<br />
    string test=ViewState["TestVal"]<br />
    //bla bla..... your query etc....<br />
    <br />
   }<br />
}


public void getid()
{
int y = Convert.ToInt32(Request.QueryString["menu_id"]);

SqlConnection con = new SqlConnection("Server=.; Database=eclsc; Trusted_Connection=yes");
SqlCommand cmd = new SqlCommand();
cmd.Connection = con;
cmd.CommandText = " select category_id from ID where menuindex='" + y + "' ";
con.Open();
string test1 = cmd.ExecuteScalar().ToString();
ViewState["TestVal"]=test1;
con.Close();
}

cheers,
Abhijit

AnswerRe: how to get the value Pin
Christian Graus24-Dec-08 23:50
protectorChristian Graus24-Dec-08 23:50 
GeneralRe: how to get the value Pin
Abhijit Jana24-Dec-08 23:57
professionalAbhijit Jana24-Dec-08 23:57 
GeneralRe: how to get the value Pin
Christian Graus25-Dec-08 0:28
protectorChristian Graus25-Dec-08 0:28 
AnswerRe: how to get the value Pin
Nishant Singh25-Dec-08 2:26
Nishant Singh25-Dec-08 2:26 
Questionhow to get the value of a variable defined in a method, in page load. Pin
R111924-Dec-08 21:43
R111924-Dec-08 21:43 
AnswerRe: how to get the value of a variable defined in a method, in page load. Pin
Nishant Singh24-Dec-08 21:45
Nishant Singh24-Dec-08 21:45 
GeneralRe: how to get the value of a variable defined in a method, in page load. Pin
Tamer Oz24-Dec-08 21:52
Tamer Oz24-Dec-08 21:52 
GeneralRe: how to get the value of a variable defined in a method, in page load. Pin
R111924-Dec-08 21:58
R111924-Dec-08 21:58 
QuestionReport opens back the main screen Pin
Member 580612224-Dec-08 19:43
Member 580612224-Dec-08 19:43 
AnswerIgnore : Repost Pin
Abhijit Jana24-Dec-08 19:49
professionalAbhijit Jana24-Dec-08 19:49 
QuestionReport opens back to the main screen Pin
Member 580612224-Dec-08 18:46
Member 580612224-Dec-08 18:46 
AnswerRe: Report opens back to the main screen Pin
Abhijit Jana24-Dec-08 18:53
professionalAbhijit Jana24-Dec-08 18:53 
GeneralRe: Report opens back to the main screen Pin
Member 580612224-Dec-08 19:32
Member 580612224-Dec-08 19:32 
GeneralRe: Report opens back to the main screen Pin
Abhijit Jana24-Dec-08 19:53
professionalAbhijit Jana24-Dec-08 19:53 
GeneralRe: Report opens back to the main screen Pin
Member 580612224-Dec-08 19:56
Member 580612224-Dec-08 19:56 
GeneralRe: Report opens back to the main screen Pin
Abhijit Jana24-Dec-08 20:06
professionalAbhijit Jana24-Dec-08 20:06 
GeneralRe: Report opens back to the main screen Pin
Member 580612224-Dec-08 20:12
Member 580612224-Dec-08 20:12 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.