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

Fetch page name from controller of other page in VIsualForce
HI All,
I have a Calculate Page which calculates some data when inculded in another Page and adds it to a custom object.
I want the controller of the Calculate Page to be able to capture the page names of the Pages it is included in.
For example . Calculate Page is included using apex:include in Samrat Page then my Calculate Page controller class should be able to display
Page Name:Samrat Page
Is there a way to do that, as using page reference i am able to get Page Name as Calculate Page everytime as the controller is used in this page. But how can i enhance it to capture The Includee page name.
Can you derive it from the URL - if you execute:
That will give you the relative URL that was requested - In your case I'd expect it to be something like:
(the parameters in angled brackets are optional you haven't mentioned if you have any) which you can then parse to extract the actual page name.
All Answers
Can you derive it from the URL - if you execute:
That will give you the relative URL that was requested - In your case I'd expect it to be something like:
(the parameters in angled brackets are optional you haven't mentioned if you have any) which you can then parse to extract the actual page name.
Yes i tried the same thing too.
But thanks for you reply.