+ Start a Discussion
Mickey Stringer 5Mickey Stringer 5 

Visualforce Pages Suddenly Not Displaying Fields

All of our Visualforce pages suddenly stopped displaying all fields and values. I see no changes made to the pages, the underlying classes, the objects and fields referenced, nor to guest profile permissions.
On the Salesforce side, the only message I see is that legacy SOAP API versions were retired today, but I don't see how that comes into play here. Furthermore, they say those versions are usable until the Winter '19 release (we are on Summer '18).

Has anyone seen this before?
Best Answer chosen by Mickey Stringer 5
Cloud AtlasCloud Atlas
Can't definitely say what the issue might be on your end. But it seems you are using VF page as a Site ( because you are using Guest Profie).
Go to Setup->Develop->Site->Site Label->Public Access Settings and check the guest profile has READ ALL permission for the object.
That is all I can recommend.

All Answers

Cloud AtlasCloud Atlas
Can't definitely say what the issue might be on your end. But it seems you are using VF page as a Site ( because you are using Guest Profie).
Go to Setup->Develop->Site->Site Label->Public Access Settings and check the guest profile has READ ALL permission for the object.
That is all I can recommend.
This was selected as the best answer
Mickey Stringer 5Mickey Stringer 5
We are using it as a site. We just turned on Read access for the object and it did not have any impact.
Mickey Stringer 5Mickey Stringer 5
And just to be clear, these pages have been around for years, and the guest user profiles used to access them have not been updated recently.
Cloud AtlasCloud Atlas
I understand that no changes have been made to profile. But a deployment from an old sandbox or recent changes in Salesforce Profile might have erased some permissions and your fields dissapeared.
So let's try with process of elimination.
Did you try to view the page as "Preview as Admin" under Sites. What was the result? If you weren't able to see any fields, check the "Site Visualforce Pages"  list under Site details and ensure that your VF page is listed there. Then go to "Public Access Setting" and check that both VF page and controller class are listed under your guest profile.
User-added image

Then scroll up to "Field Level Security" section in Guest Profile view and select the objects whose value is being shown on the page.
Click on VIEW and Check if all the fields have READ Access or not. 
After doing this, then test the page again using "Preview as Admin". 
User-added image

If all this failes, then do one thing. Open the controller class which is affiliated to the VF page. You can find it by going on the VF page and checking dependencies. There must be some queries listed in the class.
Check all those queries using Developer Console "Query Editor".
Maybe because the page and code is old, somesObject iteration is causing a problem.





 
Mickey Stringer 5Mickey Stringer 5
Whelp, Occam's razor... it was the guest profile permissions. Super confused about how they suddenly changed or stopped working, but changing them fixed it. Thanks