Hi, I am curious, how do I pass a parameter to a server side function, which looks like this?
<asp:LinkButton ID="lkbChange" runat="server" OnClick="lkbChange_Click" />
Then the serverside function will look something like this:
<script runat="server">
protected void lkbChange_Click(Object sender, EventArgs e)
{
Session["location"] = new_value;
}
<script >
And I would like something like:
<asp:LinkButton ID="lkbChange" runat="server" OnClick="lkbChange_Click(<%= value %>)" />
protected void lkbChange_Click(Object sender, EventArgs e, string value)
{
Session["location"] = value;
}
So there is also the problem to pass the parameter to the function call...
EDIT
Ok, i am beginning to feel that runat="server" is wrong. Well, I am presenting some machines and there properties. What I want here, is to filter the current resluts (of total machine's contents, history etc.) based on locations of these machines. That means the current action should stay the same - compute the same set of results, only filtered down to the currently selected location(s) - taken from the link, that changes the value of Session["location"] to e.g. everywhere.