The below VF page queries for a list of tasks assigned to a certain custom record. It works perfectly fine (shows 3 Tasks) when accessed by an internal user (/apex/siteTasks?id=xxx) while it does not show any data when the same page is accessed through Force.com Site. I have checked the usual suspects like CRUD, FLS, VF page access to the Site profile. Debug logs on the site user shows that the query in the Apex Class is returning data but the VF does not show it. Thanks in adv!

VF Page

<apex:page standardController="Cust__c" extensions="siteTasks">
<apex:pageBlock title="Tasks">
    <apex:pageBlockTable value="{!Tasks}" var="tsk">
        <apex:column title="Subject" value="{!tsk.Subject}" />
        <apex:column title="Status" value="{!tsk.Status}" />


public class siteTasks {

  public Cust__c inc {get; set;}
  public List<Task> Tasks {get; set;}

  public siteTasks(ApexPages.StandardController ctrl) {
    cust = (Cust__c) ctrl.getRecord();

    Tasks = [SELECT ID, Type, Subject, Status
                FROM Task
                WHERE WhatId =: cust.id];
  • @eyescream, any thoughts on this?
    – DCBoy
    Mar 24, 2014 at 16:35

2 Answers 2


By default, Organization-Wide Defaults (OWD) for Activities (the collective name for Tasks and Events) are set to 'Private', so no user (except for a System Administrator, who has 'View All Data' permission) should be able to see any other user's Tasks, except via the role hierarchy (manager can see their underlings' tasks).

You could try sharing the Task records with the Site guest user, though I'm not sure if this is even possible, otherwise, you'll need to set OWD for Activities to Public Read Only.


does the site user have permission to the Cust__c object, any fields, and access to the activities and its fields?

When stuff in VF is blank, but you don't get the login page, that usually means, "You've got object permissions so that page loads, but I'm going to hide the fields from you"

Can you try displaying some information on the page about the cust__c? That at least proves the permisssions aren't the issue.

  • I am able to see fields from Cust__c object on the VF page. I also double checked the FLS on Task object for the site profile and all the fields are visible.
    – DCBoy
    Mar 24, 2014 at 5:43

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .