Note that there are some explanatory texts on larger screens.

plurals
  1. POapplying display tag to my project but failed in struts config file
    primarykey
    data
    text
    <p>I am applying display tag to my jsp in struts but not able to do it please check out</p> <p>1.strutsconfig</p> <pre><code>&lt;form-beans&gt;&lt;form-bean name="DailysheetForm" type="com.myapp.struts.DailysheetForm"/&gt; &lt;/formbean&gt; &lt;action input="/" path="/DailysheetList" name="DailysheetForm" scope="request" type="com.myapp.struts.DialysheetListAction"&gt; &lt;forward name="success" path="/DailysheetList.jsp"/&gt; &lt;/action&gt; </code></pre> <p>2.Form</p> <pre><code>public class DailysheetForm extends ActionForm { // some getter and setter methods i used like receiptno protected ArrayList arraylist; public ArrayList getArraylist() { return arraylist; } public void setArraylist(ArrayList arraylist) { this.arraylist = arraylist; } </code></pre> <p>3.Action Class</p> <pre><code>public ActionForward execute(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception { ArrayList dailysheetdata; DailysheetForm dailyform = (DailysheetForm) form; Class.forName("com.mysql.jdbc.Driver"); Connection connect = DriverManager.getConnection("jdbc:mysql://localhost/Stonecrusher?" + "user=Stonecrusher&amp;password=xxxxxx"); System.out.println("Connection"+connect); dailysheetdata = StoneCrusherData.getDailysheetData(connect); dailyform.setArraylist(dailysheetdata) ; return mapping.findForward(SUCCESS); } </code></pre> <p>JSP</p> <pre><code>&lt;display:table id="data" name="requestScope.DailysheetForm.arraylist"requestURI="/DailysheetList" pagesize="10" &gt; &lt;display:column property="receiptno" title="RECEIPTNO" sortable="true"/&gt; &lt;display:column property="cutomername" title="CUSTOMER NAME" sortable="true"/&gt; &lt;/display:table&gt; &lt;display:table id="data" name="requestScope.DailysheetForm.arraylist" requestURI="/DailysheetList" pagesize="10" &gt; &lt;display:column property="receiptno" title="RECEIPTNO" sortable="true"/&gt; &lt;display:column property="cutomername" title="CUSTOMER NAME" sortable="true"/&gt; &lt;/display:table&gt; </code></pre> <p>It is not working and basically I am getting data to dailysheetdate which is arraylist in my Action Class and I want to display it in jsp with pagination. I know I was wrong please help me how to do it.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload