View Code
1. The first one is written in the program code,
2
3. In the event of clicking the value transfer, write:
4
5
6
7 Response. Redirect ("adminUpdate. aspx? UserName = "+ gvAdminInFo. selectedRow. cells [1]. text. toString (). trim () + "& userJiaoSe =" + gvAdminInFo. selectedRow. cells [2]. text. toString (). trim () +
8 "& userStart =" + gvAdminInFo. SelectedRow. Cells [3]. ToString (). Trim ());
9 copy code
10
11
12
13
14 when receiving the message on the next page:
15
16
17
18 txtUserName. Text = Request ["userName"]. ToString (). Trim ();
19 txtUserJiaose. Text = Request ["userJiaoSe"]. ToString (). Trim ();
20 txtUseruserStart. Text = Request ["userStart"]. ToString (). Trim ();
21. Copy the code
22
23
24
25
26 2. The second is written in the interface tag,
27 write in the mark as follows:
28
29 <asp: HyperLink id = HyperLink1 runat = "server" NavigateUrl = '<% # DataBinder. Eval (Container. DataItem, "SendUserName", "SendSMsg. aspx? QID = {0} ") %> 'text = '<% # DataBinder. Eval (Container. DataItem," SendUserName ") %> 'target =" _ blank ">
30 </asp: HyperLink>
31. Copy the code
32
33
34
35
36
37
38 when the program receives the message
39
40 txtUserName. Text = Request ["SendUserName"]. ToString (). Trim ();
41
42
43
44
45 3. If we have multiple values, you can also pass it like this, (this article is reproduced from http://sufei.cnblogs.com /)
46
47
48
49 Code
50 <asp: HyperLink ID = "HyperLink2" NavigateUrl = '<% # DataBinder. Eval (Container. DataItem, "ID ","~ /Admin/passwordUpdate. aspx? ID = {0} ") + DataBinder. eval (Container. dataItem, "UserName", "& UserName = {0}") %> 'runat = "server"> Reset </asp: HyperLink>