You need to sign in to do that
Don't have an account?
Ashutosh Tripathi 9
Basic: Calling a controller method on page load ?
I am trying to call a class method on the pasge load, I am not sure how can I do this.
Another one Can I pass the soql query on the page load ?
Another one Can I pass the soql query on the page load ?
<apex:page controller = "mycontroller" action = "{!mypageloadingmethod}">
if using url to pass soql query, you can use the following example in the method (which Action attribute binds to).
your url would be like:
https://xxxx.salesforce.com//?userid=005G0000004H9LY
the apex code would be like:
string userId = ApexPages.CurrentPage().getParameters().get('userId');
Hope this helps.