You need to sign in to do that
Don't have an account?

BUG Urgent: actionSupport focus attribute doesn't work in IE
Hi all,
I don't know if you have faced this issue, but looks like there is a bug (don't know if it is) is Visual Force page when user hits the tab key I want to send the focus to the next field, since I am rerendering the page/pageblock/pageitems it's losing focus, but on actionSupport "onChange" event I am setting the focus to the specific field that I want i.e. Like this
<apex:actionsupport event="onchange" rerender="pbselected, pbsEvents, pbservices,totalprice,totalextendedamt" focus="discountvalue"/>
like this but my problem is it's working fine in FireFox, but it doesn't work in IE. Has anyone faced this issue before? and any solutions/work-arounds? please let me know. This is a critical piece any help is really appreciated.
Thanks,
Rami
Message Edited by TehNrd on 10-13-2008 04:29 PM
It's associated to outputfield component.
thx
sorry meant to say inputfield
thx
Please use the SRC button when posting code.
sure, pl see below... so basically the user comes to the Qty field enters the value and hits the tab key (it should go to discount value field), the page gets rendered and the cursor loses focus even with the focus attribute, but it works fine in FireFox. Basically the whole thing is under pageblocktable.
<apex:column headerValue="Qty">
<div class="requiredInput">
<div class="requiredBlock"></div>
<apex:inputField value="{!invoicesval.invoicedetail.Quantity__c}" style="width:35px">
<apex:actionsupport event="onchange" rerender="pbselected, pbsEvents, totalprice,totalextendedamt" focus="discountvalue"/>
</apex:inputField>
</div>
</apex:column>
<apex:column >
<apex:facet name="header">Discount<br/>Value</apex:facet>
<apex:inputField id="discountvalue" value="{!invoicesval.invoicedetail.DiscountValue__c}" style="width:75px">
</apex:inputField>
</apex:column>
<apex:column >
<apex:facet name="header">Discount<br/>Type</apex:facet>
<div class="requiredInput">
<div class="requiredBlock"></div>
<apex:inputField id="discounttype" value="{!invoicesval.invoicedetail.DiscountType__c}" style="width:85px">
<apex:actionsupport event="onchange" action="{!invoicesval.validateinputdata}" rerender="pbselected, pbsEvents,totalprice,totalextendedamt,msgs"/>
</apex:inputField>
</div>
</apex:column>
<apex:column >
<apex:facet name="header">Discount<br/>Price</apex:facet>
<div class="requiredBlock"></div>
<apex:outputField id="invdiscountprice" value="{!invoicesval.calculateddiscountedprice.Discounted_Price__c}" style="width:85px" rendered="true" > </apex:outputField>
<apex:actionsupport event="onchange" rerender="totalprice,totalextendedamt"></apex:actionsupport>
</apex:column>
<apex:column >
<apex:facet name="header">Discount<br/>Percent</apex:facet>
<apex:outputField id="invdiscountpercent" value="{!invoicesval.calculateddiscount.Discount__c}" style="width:40px"> </apex:outputField>
<apex:actionsupport event="onchange" rerender="totalprice,totalextendedamt"></apex:actionsupport>
</apex:column>
<apex:column >
<apex:facet name="header">Extended<br/>Amount</apex:facet>
<apex:outputField id="totalprice" value="{!invoicesval.totalPrice.Extended_Amt__c}" style="width:85px"/>
<apex:actionsupport event="onchange" rerender="totalextendedamt"></apex:actionsupport>
</apex:column>
sorry I didn't post code using SRC button, but any update anyone in this issue...
SFCRK,
Did you ever get your actionsupport to fire on the inputfield?
I'm currently trying to get mine to work with an Inputfield of a currency field. So far I've tried onclick, onchange, onblur, onfocus, and onselect. Nothing seemed to ever happen. Just to make sure it wasn't a mistake with a re-render I even put a status on just to see if the status ever fires (it doesn't).
I'm interested in knowing what your solution was.
hi, for me also the focus attribute is not working.. did you get the solution> if so pls suggest what to do?
Hi
I am also having this isue. The focus attribute is not been respected and without it an inputfield elsewhere on the page is getting the focus after the actionsupport call.
Help !
Many thanks
Ross