Can I modify JSon result in an action filter?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • anoopx
    New Member
    • Mar 2013
    • 2

    Can I modify JSon result in an action filter?

    Hi
    I want to add some filter conditions to the result of an action. Can I do it though Action filter OnActionExecute d() since we can get the result here. It is a JSon result.
    Thanks in advance.
    Anoop X
  • r035198x
    MVP
    • Sep 2006
    • 13225

    #2
    Yes, you should be able to. Bear in mind though that they are most useful when applying them to multiple actions or applying them selectively (if possible).
    Also decide whether it's better to use IResultFilter instead of IActionFilter. Generally, use IActionFilter when changing the action (processing logic) and use IResultFilter when just changing the result. Not necessarily a hard and fast rule ofcourse.

    Comment

    • anoopx
      New Member
      • Mar 2013
      • 2

      #3
      r035198x,

      Thanks for your immediate reply. Can you please give any useful links which explain how to modify result in the IResultFilter.

      Comment

      Working...