SharePoint 2010. How to check if user has a permission to complete task in InfoPath task form?
**Is it possible to check if the user has enough permissions to complete task in InfoPath 2010? Or maybe it is possible to show to user read-only view if he has lack of the rights.**

The full description of my problem:

**Task:** approve absence of Pupil by Teacher and if approved add absence to SAP.

**I am using next approach:** When Teacher press the "Approve" button in InfoPath, first of all I invoke WebService to add record in SAP, and after it I submit the form. 

**Problem in  my approach:** if Pupil opens Teacher's task form he can press the "Approve" button and WS will be invoked, but the submiting of form fails, because Pupil can't complete Teacher's task. And, I don't know, how to forbid to invoke WS if there is a lack of the rights.

**Possible solutions:**

1. I think, that the better way in my case is to use code not in InfoPath, but in VS. But my WF is created in SPD. In such case I could create custom activity for SPD to invoke WS (or add absence to SAP), but it is an additional module, and I don't want to create it without necessity.
2. I think it is possible, to do such action using code in InfoPath.
3. May be I have to do something with user rights (to show read-only view for users with lack of rights).

But may be there is another possibility to do such typical action in SAP? 

Any suggestions are very appreciated.
SharePoint 2010. How to check if user has a permission to complete task in InfoPath task form?
===

**Is it possible to check if the user has enough permissions to complete task in InfoPath 2010? Or maybe it is possible to show to user read-only view if he has lack of the rights.**

The full description of my problem:

**Task:** approve absence of Pupil by Teacher and if approved add absence to SAP.

**I am using next approach:** When Teacher press the "Approve" button in InfoPath, first of all I invoke WebService to add record in SAP, and after it I submit the form. 

**Problem in  my approach:** if Pupil opens Teacher's task form he can press the "Approve" button and WS will be invoked, but the submiting of form fails, because Pupil can't complete Teacher's task. And, I don't know, how to forbid to invoke WS if there is a lack of the rights.

**Possible solutions:**

1. I think, that the better way in my case is to use code not in InfoPath, but in VS. But my WF is created in SPD. In such case I could create custom activity for SPD to invoke WS (or add absence to SAP), but it is an additional module, and I don't want to create it without necessity.
2. I think it is possible, to do such action using code in InfoPath.
3. May be I have to do something with user rights (to show read-only view for users with lack of rights).

But may be there is another possibility to do such typical action in SAP? 

Any suggestions are very appreciated.