You need to sign in to do that
Don't have an account?
Show ApexPages.Message in embedded visualforce page
Does <apex:pageMessages /> work the same with the VF page is embedded in a standard page?
I've added (inside the form tag)...
<apex:pageMessages />
then from the controller extn - I'm doing a
But I never see the message. I've verified that the code is executing for the ApexPages.add...
I've added (inside the form tag)...
<apex:pageMessages />
then from the controller extn - I'm doing a
ApexPages.addMessage(new ApexPages.Message(ApexPages.Severity.ERROR, 'ERROR message.'));
But I never see the message. I've verified that the code is executing for the ApexPages.add...
I had my pageReference method that was referenced in the commandLink return a void instead of a pageReference. Then I also took the rerender= "" away from the commandLink tag.
Started working.
Not sure why though.
All Answers
Please be sure to rerender the form properly, only after that the page message will appear.
If you can post your VF page than it would be easy to help you out.
Thanks,
Abhishek
Well - you can't do a rerender on the form - as it's an EMBEDDED Vf page. So, in the controller - you do a pageReference. I bet that you can't use the <apex:pageMessages/> tag in this case. It'd be good if somebody could confirm that.
Here's some of the code...
I added an id="messages" to apex:pageMessages to be able to find in the DOM and reRender="message" so that Messages gets re-rendered when the Action finishes.
So if your Class has this:
You should now get something like this:
Hope it helps someone. GLHF
Could you share your Consignment inventory code with me please?
I had my pageReference method that was referenced in the commandLink return a void instead of a pageReference. Then I also took the rerender= "" away from the commandLink tag.
Started working.
Not sure why though.