3

In almost all the examples where apex:param is used in conjunction with apex:actionfunction I have seen the value attribute of apex:param is "".

Can someone explain the logic behind this ?

I went through the doc here but still I am not clear about the usage of apex:param tag.

My understanding is apex:param sets the controller variable mentioned in assignTo with the value mentioned in the value attribute.

If my understanding is right then why value attribute is always set to "" in apex:param tag.

Can someone help ?

  • Hmm...I am also interested in this – Varun Feb 27 '18 at 0:52
1

apex:actionFunction will almost always have parameters assign the attribute value="", because the parameter will be provided by the JavaScript call. However, value is a required attribute for apex:param, so you need to provide something, but the value itself is meaningless because the calling script will provide the appropriate value.

  • Yikes I just edited my post – Aaron Wilfred Feb 27 '18 at 1:29
  • @AaronWilfred It's okay, I was still here anyways. Glad I could help! – sfdcfox Feb 27 '18 at 1:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.