| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 1580 人关注过本帖
标题:PostBackUrl传递参数的方法
只看楼主 加入收藏
水晶心
Rank: 1
等 级:新手上路
帖 子:69
专家分:0
注 册:2010-7-27
结帖率:80%
收藏
已结贴  问题点数:11 回复次数:2 
PostBackUrl传递参数的方法
我想在母版页利用 PostBackUrl这个属性传递一个ID参数到修改密码页面。不知道怎么传递,我在母版页做了个图像按钮连接到修改密码文件,可是需要传递登录人员的ID到修改密码文件,我不知道怎么写这个参数。
<td bgcolor="#9BCDFF" style="vertical-align: top; height: 39px; text-align: center; width: 192px;"><table width="213" height="128">
        <tbody>
          <tr>
            <td align="right" valign="bottom" style="width: 90px">用户:</td>
            <td align="left" valign="bottom"><asp:Label id="lblUserName" runat="server" ForeColor="Red"></asp:Label></td>
          </tr>
          <tr>
            <td align="right" style="width: 90px">角色:</td>
            <td align="left"><asp:Label id="lblRoleId" runat="server" ForeColor="Red"></asp:Label></td>
          </tr>
        </tbody>
      </table>
      <hr />
          <asp:TreeView ID="tvShow" runat="server" ExpandDepth="2">
          </asp:TreeView>
      </td>
      <td colspan="2" rowspan="3" style="vertical-align: top; width: 682px; text-align: center;">
      <table border="0" style="width: 814px" cellpadding="0" cellspacing="0">
          <tr align="center" style=" height:43px; background-image:url(<%=TemplateSourceDirectory %>/images/topback.gif)" >
            <td align="center" style="width: 120px; height: 43px;">
                <asp:ImageButton ID="ImageButton1" runat="server" ImageUrl="~/images/home.jpg" Height="22px" Width="44px" /></td>
            <td align="center" style="width:  120px; height: 43px;">
                &nbsp;<asp:ImageButton ID="ImageButton2" runat="server" ImageUrl="~/images/Relogin.jpg" Height="22px" Width="68px" PostBackUrl="Login.aspx" /></td>
            <td align="center" style="width: 120px; height: 43px;">
               <asp:ImageButton ID="ImageButton3" runat="server" ImageUrl="~/images/modifypass.jpg" Height="22px" Width="68px" PostBackUrl=/></td>
            <%--<td align="center" style="width:  120px; vertical-align: middle; text-align: center;">
                <asp:ImageButton ID="ImageButton4" runat="server" ImageUrl="~/images/hidetitle.jpg" Height="22px" Width="107px" />&nbsp;
            </td>--%>
红色字体就是那个图标按钮,其中PostBackUrl= 应该怎么写啊,请教各位高手,我想学习一下。能具体讲讲吗。
搜索更多相关主题的帖子: PostBackUrl 参数 
2010-11-22 22:39
筱晓绾
Rank: 10Rank: 10Rank: 10
来 自:湖南
等 级:贵宾
威 望:12
帖 子:512
专家分:1736
注 册:2010-9-1
收藏
得分:11 
母版页算是一个公共页面吧!不能指定某一个链接,除非你每个页面都要用到那个链接,如果是那样的话,那就在指定页面后加参数吧!
2010-11-23 12:52
水晶心
Rank: 1
等 级:新手上路
帖 子:69
专家分:0
注 册:2010-7-27
收藏
得分:0 
PostBackUrl=就是在这后面加文件路径和参数对吧,我知道怎样加文件路径,参数不会写,就想让这个修改密码图标链接到修改密码文件上,怎么传参数啊,帮帮我吧谢谢
2010-11-23 15:45
快速回复:PostBackUrl传递参数的方法
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.021389 second(s), 7 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved