Quantcast
Channel: SharePoint 2013 - Development and Programming forum
Viewing all articles
Browse latest Browse all 7589

The given guid does not exist in the term store.

$
0
0

I uploaded a document to library and want to set a column using the code snippet:

using (ClientContext context = SPHelper.GetClientContext())
            {
                List library = context.Web.Lists.GetByTitle("MyDocumentLibrary");
                FileCreationInformation fileInfo = new FileCreationInformation
                {
                    Url = "MyFileTarget",
                    Content = document.Content,
                    Overwrite = true
                };
                File file = library.RootFolder.Files.Add(fileInfo);
                ListItem item = file.ListItemAllFields;

                item["RegularColumn"] = "some data";
                item["Metadata"] = "some other data";
                item.Update();
                context.ExecuteQuery(); // "The given guid does not exist in the term store." Exception thrown
            }

Is there any fix to this exception ?

Thanks for any help.


Viewing all articles
Browse latest Browse all 7589

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>