# Multifield not being updated

**URL:** <https://forum.litium.com/t/multifield-not-being-updated/2484>\
**Category:** Questions\
**Tags:** accelerator, litium-7\
**Created:** [March 4, 2022, 1:43pm UTC](https://forum.litium.com/t/multifield-not-being-updated/2484 "2022-03-04T13:43:10Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Gonzalo](https://avatars.discourse-cdn.com/v4/letter/g/4bbf92/32.png) [@Gonzalo](https://forum.litium.com/u/Gonzalo)\
**Post date:** [March 4, 2022, 1:43pm UTC](https://forum.litium.com/t/multifield-not-being-updated/2484/1 "2022-03-04T13:43:10Z")

</div>

Hi,

Im having 2 issues:

1. This is a similar issue to this one: [Setting the values of a Multifield item - #7 by magnus.bolling](https://forum.litium.com/t/setting-the-values-of-a-multifield-item/769/7)  
where my multifield doesn’t show up in backoffice but data is in database.

2. when updating page, the multifield isn’t updated. This is the code im using:

```auto
var multiFieldList = new List<MultiFieldItem>();
var multiFieldItem = new MultiFieldItem();
   multiFieldItem.Fields.AddOrUpdateValue(firstTextFieldInMultified, "hello");
   multiFieldItem.Fields.AddOrUpdateValue(secondTextFieldInMultified, "world");
   multiFieldList.Add(multiFieldItem);
   
var pageClone = page.MakeWritableClone();
   pageClone.Fields.AddOrUpdateValue("multifieldItem", multiFieldList);
                   
    _pageService.Update(pageClone);

```

Litium version: 7.7.2  
Accelerator

---

<div class="post-metadata">

**Author:** ![NilsN](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.litium.com/nilsn/32/302_2.png) [@NilsN](https://forum.litium.com/u/NilsN)\
**Post date:** [March 4, 2022, 1:51pm UTC](https://forum.litium.com/t/multifield-not-being-updated/2484/2 "2022-03-04T13:51:13Z")

</div>

For the changes to be visible in BO you should update the `DraftPage` rather than the `Page` entity. You can update the draft page and then publish it to push the changes to the live version of the page.

> [@Need to add only one channel to a page while creating through code](https://forum.litium.com/t/need-to-add-only-one-channel-to-a-page-while-creating-through-code/771/2):
>
> You should try to use the DraftPage entity instead of the Page and then when it is ready you will do a publish on the draft. Then also back office will be updated with the same content as you have publish.

> [@The correct way to add pages by code](https://forum.litium.com/t/the-correct-way-to-add-pages-by-code/1398/3):
>
> In order for back office to have the same content from the changes you made in code, a good idea is to make the changes to a DraftPage of the new page you created and then publish that one. var draftPage = \_draftPageService.Get(page.SystemId).MakeWritableClone(); // make changes \_draftPageService.Update(draftPage); \_draftPageService.Publish(draftPage);

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex030/uploads/litium/original/1X/12eddac3b8b661de1db86af10ac8151b571e6fb9.png) [@system](https://forum.litium.com/u/system)\
**Post date:** [April 1, 2022, 1:51pm UTC](https://forum.litium.com/t/multifield-not-being-updated/2484/3 "2022-04-01T13:51:37Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
