Body: <p>I have just started to get the following error with an event form / all event forms, possibly after updating to 5.39.0 (though I have now updated to 5.40.0 and still have the error).  I have tried everything obvious, what am I missing / any ideas on how to solve this error?</p>
  <blockquote>
  <p>The requested Profile (gid=39) is disabled OR it is not configured to be used for 'Profile' listings in its Settings OR there is no Profile with that ID OR you do not have permission to access this profile. Please contact the site administrator if you need assistance.</p>
  </blockquote>
  <p><strong>Profile (gid=39) is disabled / there is no Profile with that ID</strong> - it exists and is not disabled
  <a href="https://i.sstatic.net/P5sQI.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/P5sQI.png" alt="Profile 39 exists and is not disabled" /></a></p>
  <p><strong>not configured to be used for 'Profile' listings in its Settings</strong> - I have added use as Standalone Form but to no avail (and it used to work without).  I have also used other profiles but it still throws the same error (with different gid)</p>
  <p><strong>you do not have permission to access this profile</strong> - It is throwing this error for both users and for me if I am logged in as admin user.  Access is provided for:</p>
  <ul>
  <li>CiviCRM: profile listings and forms</li>
  <li>CiviCRM: profile listings</li>
  <li>CiviCRM: profile create</li>
  <li>CiviCRM: profile edit</li>
  <li>CiviCRM: profile view</li>
  <li>CiviEvent: register for events</li>
  <li>CiviEvent: view event info</li>
  </ul>
  <p>Looking at the logs it is throwing the following error:</p>
  <pre><code>[error] 
  $Fatal Error Details = array:3 [
    &quot;message&quot; =&gt; &quot;The requested Profile (gid=39) is disabled OR it is not configured to be used for 'Profile' listings in its Settings OR there is no Profile with that ID OR you do not have permission to access this profile. Please contact the site administrator if you need assistance.&quot;
    &quot;code&quot; =&gt; null
    &quot;exception&quot; =&gt; CRM_Core_Exception {#5253
      -errorData: array:1 [
        &quot;error_code&quot; =&gt; 0
      ]
      #cause: null
      -_trace: null
      #message: &quot;The requested Profile (gid=39) is disabled OR it is not configured to be used for 'Profile' listings in its Settings OR there is no Profile with that ID OR you do not have permission to access this profile. Please contact the site administrator if you need assistance.&quot;
      #code: 0
      #file: &quot;/home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/BAO/UFGroup.php&quot;
      #line: 354
      trace: {
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/BAO/UFGroup.php:354 {
          › if (empty($fields) &amp;&amp; !$validGroup) {
          ›   throw new CRM_Core_Exception(ts('The requested Profile (gid=%1) is disabled OR it is not configured to be used for \'Profile\' listings in its Settings OR there is no Profile with that ID OR you do not have permission to access this profile. Please contact the site administrator if you need assistance.',
          ›     [1 =&gt; implode(',', $profileIds)]
        }
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Event/BAO/Event.php:1299 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Event/BAO/Event.php:1087 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Event/Form/Registration/Confirm.php:871 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php:526 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/StateMachine.php:144 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/QuickForm/Action/Next.php:43 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/packages/HTML/QuickForm/Controller.php:203 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/packages/HTML/QuickForm/Page.php:103 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Controller.php:352 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php:313 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php:69 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php:36 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm.php:1178 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/includes/civicrm.basepage.php:354 { …}
        /home/[redacted]/www/www/wordpress/wp-includes/class-wp-hook.php:303 { …}
        /home/[redacted]/www/www/wordpress/wp-includes/class-wp-hook.php:327 { …}
        /home/[redacted]/www/www/wordpress/wp-includes/plugin.php:518 { …}
        /home/[redacted]/www/www/wordpress/wp-includes/class-wp.php:763 { …}
        /home/[redacted]/www/www/wordpress/wp-includes/functions.php:1291 { …}
        /home/[redacted]/www/www/wordpress/wp-blog-header.php:16 { …}
        /home/[redacted]/www/www/index.php:17 { …}
      }
    }
  ]
  </code></pre>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2021-08-06T20:07:08.130Z
Comments.Text: do users have the permission for 'access all Custom Data'? have you recently added any new fields to this profile?
Comments.UserDisplayName: petednz - fuzion
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2021-08-07T13:32:07.077Z
Comments.Text: Users do have permission for 'access all Custom Data'. No changes have been made to that profile recently, have just created a new profile with just First and Last Names, and Email and get the same error (with the new gid).
Comments.UserDisplayName: Christopher
Tags: <wordpress><profile><error>
Title: Profile error - requested Profile is disabled OR
ThreadText: # Profile error - requested Profile is disabled OR
  
  (Asked by: username_0 on 2021-08-05)
  
  I have just started to get the following error with an event form / all event forms, possibly after updating to 5.39.0 (though I have now updated to 5.40.0 and still have the error).  I have tried everything obvious, what am I missing / any ideas on how to solve this error?
  
  The requested Profile (gid=39) is disabled OR it is not configured to be used for 'Profile' listings in its Settings OR there is no Profile with that ID OR you do not have permission to access this profile. Please contact the site administrator if you need assistance.
  
  Profile (gid=39) is disabled / there is no Profile with that ID - it exists and is not disabled
  
  not configured to be used for 'Profile' listings in its Settings - I have added use as Standalone Form but to no avail (and it used to work without).  I have also used other profiles but it still throws the same error (with different gid)
  you do not have permission to access this profile - It is throwing this error for both users and for me if I am logged in as admin user.  Access is provided for:
  
  CiviCRM: profile listings and forms
  CiviCRM: profile listings
  CiviCRM: profile create
  CiviCRM: profile edit
  CiviCRM: profile view
  CiviEvent: register for events
  CiviEvent: view event info
  
  Looking at the logs it is throwing the following error:
  [error] 
  $Fatal Error Details = array:3 [
    "message" => "The requested Profile (gid=39) is disabled OR it is not configured to be used for 'Profile' listings in its Settings OR there is no Profile with that ID OR you do not have permission to access this profile. Please contact the site administrator if you need assistance."
    "code" => null
    "exception" => CRM_Core_Exception {#5253
      -errorData: array:1 [
        "error_code" => 0
      ]
      #cause: null
      -_trace: null
      #message: "The requested Profile (gid=39) is disabled OR it is not configured to be used for 'Profile' listings in its Settings OR there is no Profile with that ID OR you do not have permission to access this profile. Please contact the site administrator if you need assistance."
      #code: 0
      #file: "/home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/BAO/UFGroup.php"
      #line: 354
      trace: {
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/BAO/UFGroup.php:354 {
          › if (empty($fields) && !$validGroup) {
          ›   throw new CRM_Core_Exception(ts('The requested Profile (gid=%1) is disabled OR it is not configured to be used for \'Profile\' listings in its Settings OR there is no Profile with that ID OR you do not have permission to access this profile. Please contact the site administrator if you need assistance.',
          ›     [1 => implode(',', $profileIds)]
        }
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Event/BAO/Event.php:1299 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Event/BAO/Event.php:1087 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Event/Form/Registration/Confirm.php:871 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Form.php:526 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/StateMachine.php:144 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/QuickForm/Action/Next.php:43 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/packages/HTML/QuickForm/Controller.php:203 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/packages/HTML/QuickForm/Page.php:103 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Controller.php:352 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php:313 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php:69 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php:36 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/civicrm.php:1178 { …}
        /home/[redacted]/www/www/wordpress/wp-content/plugins/civicrm/includes/civicrm.basepage.php:354 { …}
        /home/[redacted]/www/www/wordpress/wp-includes/class-wp-hook.php:303 { …}
        /home/[redacted]/www/www/wordpress/wp-includes/class-wp-hook.php:327 { …}
        /home/[redacted]/www/www/wordpress/wp-includes/plugin.php:518 { …}
        /home/[redacted]/www/www/wordpress/wp-includes/class-wp.php:763 { …}
        /home/[redacted]/www/www/wordpress/wp-includes/functions.php:1291 { …}
        /home/[redacted]/www/www/wordpress/wp-blog-header.php:16 { …}
        /home/[redacted]/www/www/index.php:17 { …}
      }
    }
  ]
  
  **Tags:** wordpress, profile, error
  
  > **Comments:**
  > **username_1**: do users have the permission for 'access all Custom Data'? have you recently added any new fields to this profile?  
  > **username_0**: Users do have permission for 'access all Custom Data'. No changes have been made to that profile recently, have just created a new profile with just First and Last Names, and Email and get the same error (with the new gid).  
  
  ---
  
  ## 0 answers
  
  