How can I get the Current User, who create or modify the form?

  • 26 February 2018
  • 3 replies
  • 46 views

Badge +3

Hi there,

I want to get the "Current user" who log in to the computer. When I use the "Current user" action, it just show the user who created the form, but I need to have current user who create or Modify the form to filter my different section by different user.

Is there any solution?

Thanks


3 replies

Userlevel 5
Badge +14

CurrentUser referrence provides an user who is currently logged in to the sharepoint, not the user who created an item (that's CreatedBy list field).

your problem seems to be that you use CurrentUser as default value for some form control. Default values are only evaluated in NEW form, but not in EDIT form.

use calculated value control with formula having CurrentUser reference and you'll see it work's correctly.

Badge +3

Thanks Marian,

I tried this solution it work's correctly, but I want to compair this field with the Manager Name - the type of this field is People and group- for hide or show some section.

I tried to use this action :  Current__user !=  ManagerName  then Hide the section

When Manager is open the form,  Manager section is HIDE, In case current user and manager name are the same.

Do you have any solution?

Cheers,

Userlevel 5
Badge +14

have a look on userEquals() runtime function

Reply