Sitemap

Amicuk Programming Answers

EL expression in JSF with a4j:commandLink

-0001-11-30   Views:0

Advertisement

hallo: I have a very strange problem with a el-expression. i need your help, thanks. i develop a project with JSF-RI, <rich:datascroller align="left" for="ein_post" page="#{alMessageHandler.scrollerPage}"                  

hallo:
I have a very strange problem with a el-expression. i need your help, thanks.
i develop a project with JSF-RI,
<rich:datascroller align="left" for="ein_post" page="#{alMessageHandler.scrollerPage}"
                    renderIfSinglePage="false" reRender="sc2" id="sc1" />
<rich:dataTable width="985" headerClass="form_background peTable"
                         sortMode="single" id="ein_post" rows="#{alMessageHandler.pageSize}"
                         value="#{alMessageHandler.pagedListDataModel}" var="recivedMsg"
                         rowKeyVar="index">
<rich:column width="75px" id="outbox6">
    <a4j:commandLink action="#{alMessageHandler.writeReplyMsg}"
     actionListener="#{alMessageHandler.catchMessageIdForReplay}"
     rendered="#{alMessageHandler.senders[index-(alMessageHandler.scrollerPage-1)*alMessageHandler.pageSize].activated}">
       reply
     <f:param value="#{receivedMsg.message.id}" id="receivedMessageIdForReplay"  name="receivedMessageIdForReplay"/>                              
    </a4j:commandLink>
</rich:column>
</rich:dataTable>i use a PagedListDataModel, which extends DataModel. in each message i have a link 'reply'.
On the first page(the first page of rich:datascroller) i click reply link, then call the methode "catchMessageIdForReplay" then "writeReplyMsg", well done.
but after i click the seconde page then cklick "reply" link. it would not work. it can not call method "catchMessageIdForReplay" then "writeReplyMsg".
it returned to the first page. that is to say, it is only useful on the first page.
watching: if i write the code like this "rendered="true". then no problem
that's mean el-expression "rendered="#{alMessageHandler.senders[index-(alMessageHandler.scrollerPage-1)*alMessageHandler.pageSize].activated}"" on the seconde page can not working.
Strange: i can dispaly the value of #{alMessageHandler.senders[index-(alMessageHandler.scrollerPage-1)*alMessageHandler.pageSize].activated}", the value is 'true'. but 'render' did not know the el-expression on the seconde page
anybody can tell me why, and how to solve the problem ? thanks.
Edited by: zlzc2000 on Oct 27, 2009 4:09 AM

The replay answer
Advertisement
I am not very sure about your problem, but it might be releated to the bean state if your bean is in request scope. Trying using a4j:keepAlive in your jsp and see if it works. These type of problems happen sometimes with rendered and disbled attributes.
regards,
nirvan.

Go to See the other 2 answers

EL expression in JSF with a4j:commandLink

Category:DefaultRelease time:-0001-11-30Views:130

hallo: I have a very strange problem with a el-expression. i need your help, thanks. i develop a project with JSF-RI, <rich:datascroller align="left" for="ein_post" page="#{alMessageHandler.scrollerPage}"                  [More]

AJAX: Datatable sorting using a4j:commandLink

Category:DefaultRelease time:-0001-11-30Views:130

Hi, I have been using h:commandLink to sort data-table and display UP or DOWN arrow in JSF. But, when i moved to ajax-based, a4j:commandLink to sort by data-table, sort is not happening at all. I am attaching code for a single <h:column> <h:colum[More]

JSP ${} expressions in JSF tag attributes

Category:DefaultRelease time:2015-10-11Views:130

Does anyone know why the expert group decided not to allow ${} style expressions within JSF tag attributes? I understand that a different syntax is needed to implement the 'late binding' #{} expressions used to link input controls to form beans, but[More]

Using expressions in jsf tags

Category:DefaultRelease time:-0001-11-30Views:130

I have a problem with using expressions in jsf tags! I know this topic was discussed before but it doesn`t work. I want to use the following jsf-code: <h:panel_data id="tab" var="vari" modelReference="Bean.varis"> <h[More]

Urgent -Help needed : a4j:CommandLink  'reRender ' not working.

Category:DefaultRelease time:-0001-11-30Views:130

Hi, I am using <a4j:commandLink for my application to get the ajax functinality. Here i am rerendering a data table with the id -commentsId here is the Synatax, we dont have any clue to how do we progress on this. <a4j:commandLink value="submit[More]

Passing object as parameter in JSF using h:commandLink tag

Category:DefaultRelease time:2015-10-11Views:130

Hi , I have a scenario in which i need to pass objects from one jsp to another using h:commandLink. i read balusC article "Communication in JSF" and found a basic idea of achieving it. Thanks to BalusC for the wonderful article. But i am not ful[More]

Was changed app behavior for JSF 1.1 (commandLink action)

Category:DefaultRelease time:-0001-11-30Views:130

I use very simple navigation approach. Inside commandLink tag I have set action property (new_patient): <h:panelGrid id="ACTION" columns="6" styleClass="entity-action" columnClasses="entity-action-column"> <[More]

JSF 2.0 commandLink link, outputLink, etc

Category:DefaultRelease time:-0001-11-30Views:130

I have a paragraph like below Nowis the time for all good men to come to the aid of their country. If they don'e it could be the end of us I want to put a command link in this paragraph for say "good men" so it looks like this Nowis the time for[More]

JSTL expressions  inside JSF Component

Category:DefaultRelease time:-0001-11-30Views:130

Hello * I am experiencing c:if tag issues if embedded inside h:panel tags. Nesting a single c:if tag works fine, but nesting two breaks the app. Therefore I have to seprate out the JSTL tags into there own h:panel...bit messy. Anyone else experence s[More]

How to use Type Casting in JSF Expression Language

Category:DefaultRelease time:-0001-11-30Views:130

I have an attribute CategoryId in my VO of type oracle.jbo.domain.Number. I am trying to use the expression of Boolean item in JSF as #{row.CategoryId != 4} Here is the JSF code:                       <af:column id="s141NewItem3Col" noWrap=&q[More]

Use commandLink to forward non-jsf page cause other commandLink invalidate

Category:DefaultRelease time:-0001-11-30Views:130

Hi : I use commandLink to forward to non jsf page , after click the link , it worked , success to 1.jsp. Then I click another link , the other commandLink doesn't work. any one have the same problem ? JSF page: <h:commandLink action="#{MenuHandler[More]

Hot
i am getting below error when i execute a procedure.. Error : ORA-04030: out of process memory when trying to allocate 16408 bytes (koh-kghu call ,pmucalm coll)user11977262 wrote: I am getting the same error while doing online redefinition (dbms_rede [More]
hi i am looking for the best affordable solution for HD projection. i will be shooting and editing a 18min video, probably on sony xdcam ex1 editing on my g5 fcp 6 system. i don't want to down-convert for projection and am considering to buy a mac mi [More]
Hello, The mobile sales client comes with an Document Generation tool to fill Word Document Templates with SAP data on demand. Because of legal issues, we do not want to allow anyone to be able to modify the generated word document. Using the permiss [More]
I have lost my contacts on my PC in Outlook. I can see them on my iPad. I would like to get them back on my PC. I think I may have removed iCloud from the PC and I can't see anything on the iCloud from the PC. Please help.This resolved my problem, bu [More]
What happens if we change a VHD file referenced by a CLIP XML file after we have created the XML file.  The MD5 of the VHD files is stored int he CLIP XML file.  Does this have any bearing on the actual compilation? Say hello to my little friend. RFC [More]
Why do I have that annoying #1 showing? How do I get rid of it? Is it somehow connected to photostream sharing on my iPhone?I just solved this issue. It does have everything to do with photo stream. Once I opened up icloud and photo stream and unsubs [More]
Hi experts System is not deleting the reservation documents automatically even the document creation date is more than 30 days. while, my settings in SPRO-Materials Mnagement-Inventory Management and Physical Inventory-Reservation-Define Default Valu [More]
I need help... Since downloading the latest snow leopard, I cant open most of my pictures in iphoto or play most of my music in Itunes.Before you bought Snow Leopard, did you check that your machine met the specifications?   Have you enough memory, i [More]
it will not let me update my adobe flash player plug-in. I turned off all my firewalls and still wont load!!I'm sorry. I wish that I could help you with this. But if you are getting a message that the card is now being declined, there must be some re [More]
Hello all, I had couple of questions( i have already tried searching in the oracle docs and metalink notes, but could not find anything on it). First thing, looks like oracle 11g OEM Grid requires a Weblogic server. Which is fine, But wanted to know [More]