Answers.Body: <p>The class for adding an activity to a case is <em>CRM_CivirulesActions_Activity_AddToCase</em> (and so will be in folder ...../civirules/CRM/CivirulesActions/Activity). The actual processing of the action takes place in the function <em>executeApiAction</em>, I would start debugging in that function and the <em>processAction</em> function in the parent class.</p>
  <p>There is a CiviCRM Developer Guide if you have not found it already: <a href="https://docs.civicrm.org/dev/en/latest/" rel="nofollow noreferrer">https://docs.civicrm.org/dev/en/latest/</a></p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-12-20T13:10:03.533Z
Answers.Text: Thanks. I'll have a go.
Answers.UserDisplayName: gillenpj
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-03-21T09:22:28.313Z
Answers.Text: Regarding your first comment, > I have working CivRules adding new cases with adding the Open Case
  > activity, I can not judge why yours is not working. Do you have any
  > programming skills? – ErikH - CiviCooP Dec 19, 2022 at 6:41 May I ask for more details of your configurations and if there are any things to be aware of in the setup you achieved?
Answers.UserDisplayName: Hikaru
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-12-20T12:38:23.030Z
Answers.LastActivityDate: 2022-12-20T12:38:23.030Z
Answers.UserDisplayName: ErikH - CiviCooP
Body: <p>I'm trying to write a CiviRule with the trigger &quot;Custom Data on Individual Changed&quot; and the linked conditions &quot;Contact Custom Field Changed is one of&quot; AND &quot;Field Value Comparison&quot;. Using the simple linked action &quot;Add Tag to Contact&quot; I've been able to verify that this performs as expected. However, when I instead use the linked action &quot;Create case activity&quot; (see details below) nothing appears to happen. I'm trying to configure this rule such that a case of a particular type (Volunteer Recruitment - befriending) is created when the rule is triggered. (To be clear, this case type has already been set up in  the system.) Any suggestions would be greatly appreciated. Thanks.</p>
  <p><a href="https://i.sstatic.net/q5oY3.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/q5oY3.png" alt="enter image description here" /></a></p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-12-19T06:41:45.283Z
Comments.Text: I have working CivRules adding new cases with adding the Open Case activity, I can not judge why yours is not working. Do you have any programming skills?
Comments.UserDisplayName: ErikH - CiviCooP
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-12-20T12:12:29.297Z
Comments.Text: Hi ErikH. I don't have web development type programming skills and I'm definitely not an IT professional but I do have decent programming skills in Python, SQL, R, basic Linux stuff, etc. I'd be willing to give it a go if I could get under  the hood of what may be going wrong here. CiviRules is great but I've run into this and one other issue which together are creating a big impediment to my finishing up a volunteering project for a small charity here in the UK. I'd be more than willing to roll up my sleeves to figure out what may be going wrong.
Comments.UserDisplayName: gillenpj
Tags: <civirules>
Title: Is it possible to open a case (of a certain type) as the action of a CiviRule?
ThreadText: # Is it possible to open a case (of a certain type) as the action of a CiviRule?
  
  (Asked by: username_0 on 2022-12-17)
  
  I'm trying to write a CiviRule with the trigger "Custom Data on Individual Changed" and the linked conditions "Contact Custom Field Changed is one of" AND "Field Value Comparison". Using the simple linked action "Add Tag to Contact" I've been able to verify that this performs as expected. However, when I instead use the linked action "Create case activity" (see details below) nothing appears to happen. I'm trying to configure this rule such that a case of a particular type (Volunteer Recruitment - befriending) is created when the rule is triggered. (To be clear, this case type has already been set up in the system.) Any suggestions would be greatly appreciated. Thanks.
  
  [![enter image description here](https://i.sstatic.net/q5oY3.png)](https://i.sstatic.net/q5oY3.png)
  
  **Tags:** civirules
  
  > **Comments:**
  > **username_1**: I have working CivRules adding new cases with adding the Open Case activity, I can not judge why yours is not working. Do you have any programming skills?  
  > **username_0**: Hi username_1. I don't have web development type programming skills and I'm definitely not an IT professional but I do have decent programming skills in Python, SQL, R, basic Linux stuff, etc. I'd be willing to give it a go if I could get under  the hood of what may be going wrong here. CiviRules is great but I've run into this and one other issue which together are creating a big impediment to my finishing up a volunteering project for a small charity here in the UK. I'd be more than willing to roll up my sleeves to figure out what may be going wrong.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2022-12-20. Score: 1
  
  The class for adding an activity to a case is *CRM\_CivirulesActions\_Activity\_AddToCase* (and so will be in folder ...../civirules/CRM/CivirulesActions/Activity). The actual processing of the action takes place in the function *executeApiAction*, I would start debugging in that function and the *processAction* function in the parent class.
  
  There is a CiviCRM Developer Guide if you have not found it already: <https://docs.civicrm.org/dev/en/latest/>
  
  > **Comments:**
  > **username_0**: Thanks. I'll have a go.  
  > **username_2**: Regarding your first comment, > I have working CivRules adding new cases with adding the Open Case > activity, I can not judge why yours is not working. Do you have any > programming skills? – username_1 - username_1 Dec 19, 2022 at 6:41 May I ask for more details of your configurations and if there are any things to be aware of in the setup you achieved?  
  
  ---
  
  