Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • kajal_sawant 3 posts 73 karma points
    1 week ago
    kajal_sawant
    0

    UserService.SavedUserGroup Not Saving data on 1st time.

    Hello all,

    I am facing issues while saving UserService.SavedUserGroup delegate, when i fired save event in Users Group and change its permissions,it's not reflecting changes on 1st time and its save the changes on 2 time.

    Thank you.

  • Alex Skrypnyk 4856 posts 17520 karma points MVP 2x admin c-trib
    1 week ago
    Alex Skrypnyk
    0

    Hi Kajal

    Welcome to our forum!

    Can you show the code how do you do that?

    Alex

  • kajal_sawant 3 posts 73 karma points
    1 week ago
    kajal_sawant
    0

    Hello Alex,

    Thanks for approve

    UserService.SavedUserGroup += GroupServiceSaved;
    
    public void GroupServiceSaved(IUserService sender,Umbraco.Core.Events.SaveEventArgs<IUserGroup> args)
             {
                IEnumerable<IContent> contents;
                contents = objCommonRepository.GetContentType("home");
    }
        }
    

    This is code sample i implemented. When i hit Save its come on this event and execute every single line but not save changes. 2nd time its working as expected.

Please Sign in or register to post replies

Write your reply to:

Draft