Note: Please do not write this off as a duplicate. Kindly read through my complete question.
I have 2 Web API controllers A and B. I need to call a method from controller B in a method in controller A. This, I need it to happen, after some actions have been performed.
class AController : ApiController{
public IHttpAction SomeMethod(){
//some action I need to finish before the call for Controller B
//Call for Controller B
}
}
class BController : ApiController{
public IHttpActionResult AnotherMethod(){
//Some code that I want to be executed after the code in Controller A
}
}
Please do not suggest me to create another class with a common functionality which is the solution that I commonly found across the web while looking for a solution. I have no common functionality. I just want the execution of code in a linear manner. One after the other. Hopefully, I have been clear. Any help would be appreciated.