{"id":12729,"date":"2013-08-18T07:23:00","date_gmt":"2013-08-18T07:23:00","guid":{"rendered":"https:\/\/viewmyprojects.com\/winwirewp\/?p=12729"},"modified":"2025-01-28T11:40:41","modified_gmt":"2025-01-28T11:40:41","slug":"sharepoint-data-view-web-part","status":"publish","type":"post","link":"https:\/\/viewmyprojects.com\/winwirewp\/blog\/sharepoint-data-view-web-part\/","title":{"rendered":"SharePoint Data View Web Part"},"content":{"rendered":"\n<p>This post covers yet another nightmare that I had faced while working on one of the \u201cterrible\u201d areas in SharePoint. Yep \u2013 this post will cover Data View Web Part. The reason why I call it \u201cterrible\u201d is not because it is difficult to understand; it\u2019s because with Data View Web Part(DVWP), one tends to run into problems that are difficult to solve, OR have unknown reasons behind them. The root cause behind this? The shared error message is very generic.<\/p>\n\n\n\n<p>I faced a similar problem sometime ago. Let\u2019s take a look at it; this problem could serve as a limelight for a few others that encompass the same issue.<\/p>\n\n\n\n<p><strong>The Problem<\/strong><\/p>\n\n\n\n<p>In this particular situation, the Data View Web Part inserted on a page displays an error message instead of the actual content. The error message is:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"293\" src=\"https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/Code-1-1024x293-1.webp\" alt=\"\" class=\"wp-image-18031\" srcset=\"https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/Code-1-1024x293-1.webp 1024w, https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/Code-1-1024x293-1-300x86.webp 300w, https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/Code-1-1024x293-1-768x220.webp 768w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>We faced this issue after deploying the SharePoint Site from one location to another through Site Backup-Restore methodology AND the first time a NON-Site Collection Administrator logged into the page where the web part is hosted. The second a site administrator logs in and logs off, and then signs in again as the normal user, the error is gone.<\/p>\n\n\n\n<p>It wasn\u2019t just this; the error comes back again, inconsistently. Every time, though, it gets resolved immediately after the swap of logins. The log files were also not helping much. Below is a snapshot of what the log file message looked like.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"842\" src=\"https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/Code-2-1024x842-1.webp\" alt=\"\" class=\"wp-image-18032\" srcset=\"https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/Code-2-1024x842-1.webp 1024w, https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/Code-2-1024x842-1-300x247.webp 300w, https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/Code-2-1024x842-1-768x632.webp 768w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Here is a related link which explains the same problem. The proposed solution here is to remove and add the user to the security group OR to the site directly.<a href=\"http:\/\/social.technet.microsoft.com\/forums\/en-US\/sharepointgeneral\/thread\/7bbe8087-bd12-4ace-9fa5-578f6fdb4217\" target=\"_blank\" rel=\"noopener\">http:\/\/social.technet.microsoft.com\/forums\/en-US\/sharepointgeneral\/thread\/7bbe8087-bd12-4ace-9fa5-578f6fdb4217<\/a><\/p>\n\n\n\n<p>We tried their solution \u2013 and it did not help us.<\/p>\n\n\n\n<p><strong>Solution<\/strong><\/p>\n\n\n\n<p>This error occurs when the \u201cAllowPersonalization\u201d property of the Web Part Zone is set to false, and a user with less privilege tries to access the zone. This leads to the WebPartPageUsageException. This could be overcome by just setting the AllowPersonalization property to true.<\/p>\n\n\n\n<p><em>NOTE: Please respond if anyone has a different thought on the whole topic.<\/em><\/p>\n","protected":false},"excerpt":{"rendered":"<p>This post covers yet another nightmare that I had faced while working on one of the \u201cterrible\u201d areas in SharePoint. Yep \u2013 this post will cover Data View Web Part. The reason why I call it \u201cterrible\u201d is not because it is difficult to understand; it\u2019s because with Data View Web Part(DVWP), one tends to&hellip; <a class=\"more-link\" href=\"https:\/\/viewmyprojects.com\/winwirewp\/blog\/sharepoint-data-view-web-part\/\">Continue reading <span class=\"screen-reader-text\">SharePoint Data View Web Part<\/span><\/a><\/p>\n","protected":false},"author":46,"featured_media":16744,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_eb_attr":"","_uag_custom_page_level_css":"","footnotes":""},"categories":[1],"tags":[],"class_list":["post-12729","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-uncategorized","entry"],"acf":[],"featured_image_src":"https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SharePoint-Data-View-Web-Part-graphic.webp","author_info":{"display_name":"Suneetha","author_link":"https:\/\/viewmyprojects.com\/winwirewp\/author\/suneetha\/"},"views":3673,"uagb_featured_image_src":{"full":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SharePoint-Data-View-Web-Part-graphic.webp",800,440,false],"thumbnail":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SharePoint-Data-View-Web-Part-graphic-150x150.webp",150,150,true],"medium":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SharePoint-Data-View-Web-Part-graphic-300x165.webp",300,165,true],"medium_large":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SharePoint-Data-View-Web-Part-graphic-768x422.webp",750,412,true],"large":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SharePoint-Data-View-Web-Part-graphic.webp",750,413,false],"1536x1536":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SharePoint-Data-View-Web-Part-graphic.webp",800,440,false],"2048x2048":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SharePoint-Data-View-Web-Part-graphic.webp",800,440,false],"post-thumbnail":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SharePoint-Data-View-Web-Part-graphic.webp",800,440,false]},"uagb_author_info":{"display_name":"Suneetha","author_link":"https:\/\/viewmyprojects.com\/winwirewp\/author\/suneetha\/"},"uagb_comment_info":0,"uagb_excerpt":"This post covers yet another nightmare that I had faced while working on one of the \u201cterrible\u201d areas in SharePoint. Yep \u2013 this post will cover Data View Web Part. The reason why I call it \u201cterrible\u201d is not because it is difficult to understand; it\u2019s because with Data View Web Part(DVWP), one tends to&hellip;&hellip;","_links":{"self":[{"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/posts\/12729","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/users\/46"}],"replies":[{"embeddable":true,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/comments?post=12729"}],"version-history":[{"count":3,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/posts\/12729\/revisions"}],"predecessor-version":[{"id":22564,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/posts\/12729\/revisions\/22564"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/media\/16744"}],"wp:attachment":[{"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/media?parent=12729"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/categories?post=12729"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/tags?post=12729"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}