1
On returning a Partialview my action can both have as a return Actionresult as a Partialviewresult.
public PartialViewResult Franquias()
{
return PartialView("_Franquias");
}
Or
public ActionResult Franquias()
{
return PartialView("_Franquias");
}
The following question Difference between Viewresult and Actionresult already speaks on the subject, however my doubts are:
What would be the difference between the two options? (this has already been answered /a/124688/5846)
But still remains the following doubt: On the return of my Action, when it makes a return PartialView
, what would be more appropriate to use, the Actionresult or the Partialviewresult?
I don’t see it as duplicated, because the other question is about Viewresult and Actionresult and mine is about Partialviewresult and Actionresult, although the answer talks about what each of the types is, but my question is not answered there.
– Pablo Tondolo de Vargas
Pablo, it’s duplicated because the answer is exactly the same.
– Jéf Bueno
what would be the difference between each yes, is answered there, but what would be more appropriate to use is not answered in that question
– Pablo Tondolo de Vargas
@Pablotondolodevargas you would like to know what are the appropriate scenarios to use the
PartialView
or when to use?– gato
@cat made an edit on the doubt. I think now it’s become clearer
– Pablo Tondolo de Vargas
@Pablotondolodevargas The other dup answers another question.
– Jéf Bueno
Now I agree that it is duplicated, when I researched about it I only searched inside the C tag#.
– Pablo Tondolo de Vargas