You need to sign in to do that
Don't have an account?
Anuradha Hiremath
Display Standard Account Object Records on VF Page
Hi everyone,
I am learning SF....And now i am at the stage where i have been given a assignment and it says:
1)Need to fetch all the Account records on my VF Page...
2)I have written the Query as : Select AccountNumber,Account.Name From Account...
3) I have created a VF Page and also binded it with custom Controller...
4) Now i want to fetch the AccountNumber and AccountName on the VFPage...How should i write my program on VFPage as well as Controller.....
I tried doing it myself, didn't work up to the expectation..
Any suggestions would be valuable..
VFPage
ControllerPage
I am learning SF....And now i am at the stage where i have been given a assignment and it says:
1)Need to fetch all the Account records on my VF Page...
2)I have written the Query as : Select AccountNumber,Account.Name From Account...
3) I have created a VF Page and also binded it with custom Controller...
4) Now i want to fetch the AccountNumber and AccountName on the VFPage...How should i write my program on VFPage as well as Controller.....
I tried doing it myself, didn't work up to the expectation..
Any suggestions would be valuable..
VFPage
ControllerPage
Method 1: With Controller Class:
Apex Class: Visual Force Page:
Method 2: WIthout Controller Class.
You can also use the standard controller to display the records in your visualforce page.
Here is the sample code to display all accounts in the visualforce page. No Controller(Apex Class) Required.
If this clarifies and resolves your query kindly mark this as best answer :)
If you want to get all records in account then you do not need to write apex class with out writing apex class also you can get the record using bellow code but if you want to get particular records then you need to write apex class.
if you want to get paricular records only particular records use bellow code
apexclass: visuval force page
Thank you
Really Nice Expalaination to Freshers.
Thanks,
Soundar.
I want to update that value into 'xyz' and show in vf page. Write the apex class controller for this scenario.