My Java code: String JOBNUMBER = params.get("jobnumber").toString(); list = DBUtils.retrieveJob(JOBNUMBER); if(list.size() == 0){ */setResponsePage(SearchError.class);/* }else{ final DataView dataView = new DataView("jobs", new ListDataProvider(list)) { @Override protected void populateItem(final Item item) { final MYJobBean job = (MYJobBean) item.getModelObject(); item.add(new Label("label1", job.getJobNumber())); item.add(new Label("label2", job.getJobType())); item.add(new Label("label3", job.getJobClass())); }
}; dataView.setItemsPerPage(10); add(dataView); add(new CustomPagingNavigator("navigator", dataView)); And my mark up is : <br> <wicket: extend> <div wicket:id="navigator"></div> <p class="jobdata_p"> Job Number </p> <p class="jobdata_p"> Job Type </p> <p class="jobdata_p"> Job Class </p> <p class="jobdata_p1"> </p> <p class="jobdata_p1"> </p> <p class="jobdata_p1"> </p> <div wicket:id="navigator"></div> </wicket: extend> I want to replace the "setResponsePage(SearchError.class);" so that i can get rid of extra page.... Initially i tried to add extra label in if condition and mark up for that but it did not work. I am new to wicket and havent got hold of it yet Martin Grigorov-4 wrote > Hi, > > What did you try so far ? > > Martin Grigorov > Wicket Training and Consulting > > > On Sat, Jun 21, 2014 at 4:14 PM, K < > kondetiudaykiran@ > > wrote: > >> Hi >> >> I am trying to build a web application in which i have to display list of >> items on search... >> >> this part has been done but i have to add a errror message in the same >> page >> if the search result comes out null... >> >> I am using DataView for displaying the results. using condition in java >> is >> simple but for the unreachable id that i mention in condition the mark up >> is >> not being rendered if the condition is true. >> >> any help is well appriciated... >> >> Thanks >> >> ----- >> >> K >> -- >> View this message in context: >> http://apache-wicket.1842946.n4.nabble.com/Error-search-message-in-same-page-tp4666331.html >> Sent from the Users forum mailing list archive at Nabble.com. >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: > users-unsubscribe@.apache >> For additional commands, e-mail: > users-help@.apache >> >> ----- K -- View this message in context: http://apache-wicket.1842946.n4.nabble.com/Error-search-message-in-same-page-tp4666331p4666354.html Sent from the Users forum mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org