Copied to clipboard

Flag this post as spam?

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

  • David McDonnell 52 posts 248 karma points
    Jan 10, 2020 @ 16:06
    David McDonnell

    Member Saving Event Set Custom Properties

    I am trying to set a custom value on the member item when the member is created for the first time.

    But when I call the save method on the member the custom property value does not appear in Umbraco CMS but debugging the code I can see the custom properties have their value set in after the setValue method. Any ideas why this is not presenting or saving in Umbraco 8 CMS? There are no errors thrown.

        private void MemberService_Saving(IMemberService sender, SaveEventArgs<IMember> e)
                    foreach (IMember member in e.SavedEntities)
                        if (member.Id <= 0)
                            var guidId = Guid.NewGuid().ToString();
                            member.SetValue("customFieldName", guidId);
                            sender.Save(member, false);
  • Alex Skrypnyk 5783 posts 22047 karma points MVP 4x admin c-trib
    Aug 14, 2020 @ 00:37
    Alex Skrypnyk

    Hi David

    Did you solve this issue?

    What is the problem?



Please Sign in or register to post replies

Write your reply to: