There is an Employee Application Form – any leave application form. When drafting an InfoPath Form in SharePoint, if you want the Form to be auto filled by the User Details then on Form Load you need to put the following rules.
Make sure that the Employee is not blank, else on every Form Load it will pick fresh User Name. If as a System Administrator you try to open someone ele’s form, your User details will pop up.
Form Load Rules:
Condition: When Employee Name is Blank
UserName=Username(). The current Username() will be used to query the UserName field in the UIL List in SharePoint
Query UIL List as a Data Connection
Then, pick up the information
EmployeeTitle = Jobtitle;
Department = Department;
DisplayName=Concat(LastName,” ,”, FirstName);