Execute Task A from another Task

Harpreet_KaurHarpreet_Kaur Customer IT Monkey ✭
Hi All, 

I have created a Task in PowerShell to Set the Actual End date on an Incident in SCSM. Once this is done, I want to trigger the "Assign Analyst by Group" Task by Cireson, such that the pop up for it opens and lets the user to assign the analyst by group. 
I can easily find the task using:  Get-SCSMConsoleTask -Name "Cireson.AssignAnalystByGroup.Task"   
But cant figure out a command to run this task. 

Can anyone suggest if they know how can I achieve this? 

Any help will be appreciated!

Best Answer

Answers

  • Tony_CollettTony_Collett Cireson Support Super IT Monkey ✭✭✭✭✭
    Hi Harpreet, 

    I don't think it's possible to be able to run 2 tasks from one action. It likely would be a limitation with SCSM. 

    Is the Set Actual End Date task automatically run, presumably from resolving an Incident? If so, how would the script know which user to be prompted to Assign Analyst By Group?
  • Harpreet_KaurHarpreet_Kaur Customer IT Monkey ✭
    Hi Tony, 
    Thanks for the response. The Set Actual End Date task is not running automatically. I have written a Code and created a task on the incident form. So what I am looking at achieving is: 

    When a user click on this custom task, it sets the actual end date of the task (which works as  it should). And after this I want the "Assign Analyst by Group" task gets triggered (pop up window appears). If I knew the code behind "Assign Analyst by Group", I would be able to script it along with the code I wrote for Set actual end date. 

    So am trying to find out a way this can be achieved or anything similar.
  • Brett_MoffettBrett_Moffett Cireson PACE Super IT Monkey ✭✭✭✭✭
    Great question @Harpreet_Simaar
    @Tony_Collett is right in as much as the SCSM Console is not designed to call tasks from code.
    However, if you were trying to achieve the same thing via the Cireson portal then this would be a case of adding in the On.Click command for the task you want to run and it should then execute also.

    We will ask internally if anyone has found a way to call a task from PowerShell, or if there is a way to call our code direct from PowerShell to see if this can work int he console also.

    Stay tuned.....

  • Harpreet_KaurHarpreet_Kaur Customer IT Monkey ✭
    Thanks Brett. Will wait :smiley:
  • Harpreet_KaurHarpreet_Kaur Customer IT Monkey ✭
    Thanks Brett. 
This discussion has been closed.