<INPUT TYPE="checkbox" NAME="selectedItems"  VALUE="<bean:write name="item" property="selectedItems"/>" <bean:write name="response" property="btnTakeChecked"/> />response中的btnTakeChcked为 "checked" or ""

解决方案 »

  1.   

    在form里把checkbox的初值设为选中的的那个要返回的值.
      

  2.   

    在form里把checkbox的初值设为选中的的那个要返回的值.
      

  3.   

    也是struts学习中
    只能帮楼主顶了
      

  4.   

    默认的选中值为"on",你只要设置form中对应于jsp页面属性checkBox的值为on就可以了。
      

  5.   

    晕。。道理一样啊!<option value="" selected></option>
      

  6.   

    我是说用struts标记
    如:
                  <html:select property="saleCd">
                    <logic:present name="kse.saleCd_sel">
                      <html:options labelName="kse.saleCd_lbl" name="kse.saleCd_sel"/>
                    </logic:present>
                  </html:select>
    怎样设置某一项被选中
      

  7.   

    哈哈哈!这方面我可颇有心得,上一个项目为此我研究了一下午,几乎没干别的活儿。默认是on,选中是为1,当再去掉选中时为0;即选中只有1,不选中时可能为on也可能为0。
      

  8.   

    <html:select property="saleCd"  value=“<%=value%>”>
                    <logic:present name="kse.saleCd_sel">
                      <html:options labelName="kse.saleCd_lbl" name="kse.saleCd_sel"/>
                    </logic:present>
                  </html:select>
    ni de xie fa bu tai hao gai wei ru xia 
    <html:select property="saleCd"  value=“<%=value%>”>
    <html:options Collection=“kse.saleCd_lbl"/>
    </html:select>