zoukankan      html  css  js  c++  java
  • asp:DetailsView

    Microsoft User control asp:DetailsView Co-operation with asp:SqlDataSource

    1. asp:dataSource have many way to filter database

     First solution is :    

                  <...

                     FilterExpression=" textname = '{0}' ">
                    <FilterParameters>
                        <asp:ControlParameter ControlId="textname " PropertyName="SelectedValue"/>
                    </FilterParameters> when the anto dropdownlist refresh which selectedvalue will be working on.

      Second solution is :

                <.....

                     OnSelecting="dataResources_Selecting">
                    <SelectParameters>
                        <asp:ControlParameter ControlID="txt" Name="text" PropertyName="Text"
                            DefaultValue="%" />
                        <asp:QueryStringParameter Name="txt1" QueryStringField="txt1" />
                    </SelectParameters>

                  protected void dataResources_Selecting(object sender, SqlDataSourceSelectingEventArgs e)
                 {      ......     }

    third solution strainghtaway

                     

    2. asp:DetailsView with asp:sqldatasource have

    DetailsView1.DefaultMode = DetailsViewMode.Insert; / Update

    SqlDataSource1.InsertParameters

    SqlDataSource1.Insert()

  • 相关阅读:
    NLP---word2vec的python实现
    matplotlib---Annotation标注
    matplotlib---legend图例
    matplotlib---设置坐标轴
    windows下右键新建md文件
    vue+webpack+npm 环境内存溢出解决办法
    element-ui tree树形组件自定义实现可展开选择表格
    vue-动态验证码
    ES6 数组函数forEach()、map()、filter()、find()、every()、some()、reduce()
    eslint配置文件规则
  • 原文地址:https://www.cnblogs.com/sandy_liao/p/1750211.html
Copyright © 2011-2022 走看看