SP2013 Teamsites: Rebuilding webpart pages as wiki pages via PowerShell

Afternoon all,
Hopefully someone can give me a hand with this one.  Here's my scenario; -
SharePoint 2007 to SharePoint Online Migration.  I'm looking specifically at team sites (non-Publishing sites) in particular. Our SP2007 team sites all have web part pages (default.aspx).  In SPO, these default to Wiki Pages.
Our migration tool of choice (Metalogix Content Matrix) is having some problems converting from Sp2007 Web Part Pages to SPO Wiki Pages.  I'm finding that it's creating the wiki page but closing all the web parts within it.  This one step has now
led to me and my team having to rebuild these manually.
Therefore, what I'm wondering is whether it's possible to populate wiki pages with web parts via the SPO PowerShell toolset?
Hope that's clear, but please let me know if there's anything that needs clarifying.
Steven Andrews
SharePoint Business Analyst: LiveNation Entertainment
Blog: baron72.wordpress.com
Twitter: Follow @backpackerd00d
My Wiki Articles:
CodePlex Corner Series
Please remember to mark your question as "answered" if this solves (or helps) your problem.

Similar Messages

  • Creating a new library for Webpart pages, or wiki pages

    We are using sp2013 in O365, on a site collection that is using the publishing feature.
    We want to create another library for content pages where we can create either Webpart pages or Enterprise Wiki pages.  I can create a new library and add the appropriate content types so that those types of pages are options when creating a new page. 
    But when I open the library and try to create a page based on the "(Enterprise Wiki Page) Basic Page" page layout (or any other page layout content type that I added to that library), the dialog comes up and shows it will save to the "/pages/"
    library (it is shown in the un-editable part of the "URL Name field"), and not in the new library where I initiated the creation request.  When I click save, I get a correlation ID error.
    Am I doing something wrong here?

    Hi ,
    I could reproduce this issue in my SharePoint 2013 Online when I created a new document library and add “Enterprise Wiki Page” content type into the library then create a page using this content type.
    It seems that publishing pages only can be created in the Pages library. And the SharePoint Publishing Infrastructure can only handle a single Pages library per Web site, it's a physical limitation of the software. If you want to create
    multiple Pages libraries, You could create sub webs to do it.
    Also, as there is a Correlation ID about this issue, you can use it to check more information about this issue. However, in SharePoint Online, we could not see the log files, they are controlled by Microsoft. I suggest you create a new thread on Office
    365, there are some backend engineers who can check the log. You will get better help with SharePoint Online.
    Office 365 forum:
    http://community.office365.com/en-us/f/default.aspx
    Best Regards,
    Wendy
    Forum Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Wendy Li
    TechNet Community Support

  • Error when creating a webpart page in site pages - Sharepoint 2013

    Hi,
    I am getting Unexpected error when creating a new webpart page in site pages on sharepoint 2013 site.
    I have no clue on this.
    Any help is much appreciated.
    Thank in advance.
    Smile Always

    Hi Smile,
    For troubleshooting this issue, let's verify the followings:
    Whether you can create wiki pages well.
    Whether this issue occurs for other sties.
    Whether all users have this issue. Please test with Site administrator, compare the result.
    As Naveen said, please check the log file to find more information about this issue. The path of the log file is: C:\Program Files\Common Files\microsoft shared\Web Server Extensions\15\LOGS.
    Best Regards,
    Wendy
    Wendy Li
    TechNet Community Support

  • Webpart page in a publishing site

    I have a Sharepoint 2013 on premise environment. Does anyone know how to add a webpart page or add the functionality so that it’s a little easier and more consistent?
    Here is an article outlining how one might add a wepart page but my issue is that even when I go to the sitepages library and hit add new document from the files tab, webpart page is not available? 
    I am working in a publishing site and would really like this page type back. My users do not like the new page layout and prefer the old webpart page options.
    http://community.bamboosolutions.com/blogs/sharepoint-2013/archive/2012/11/05/how-to-create-a-web-part-page-in-sharepoint-2013.aspx

    Under page layouts I have "site can use any page layout"  The problem that I am having is that this site was created as a publishing site. It seems when a site is created as a publishing site (as opposed to creating a teamsite and enabling
    the publishing feature) you do NOT get the same options when creating a new page.
    On the Publishing site when I create a page, I get one big column which my users can edit. Under the "Page" tab in the ribbon menu we have the option to adjust the "Page Layout" which seems to offer some options but does not function
    like the old webpart page where you can adjust columns .  The options listed here are a bit limited and overly complicated for my user group.
    On the Teamsite, with publishing enabled, when I create a page I also get one big column that my users can edit.  under the "Page" tab there is NO page layout button.  Under the Format Text tab there is a "Text Layout" button. 
    This is what my users are looking for.  This button gives my users the ability to quickly and easily change the column structure of the site.  It is simple and perfect. 
    Any idea how to add the "Text Layout" button to a pub site?

  • How to copy a page( webpart page) with its content using client side.

    How to copy a page(in my case  webpart page) with its content(it may contain webparts) using client code (i mean using SPservices or ECMA script).
    What i am planning is ,to give end user a page where it will contain text box to specify  name of page and a button with the help of  content editor webpart.
    where on click of button we need to write client side code such that it should create a new page from a existing page in a library with given name by user.
    Any suggestion would be helpful. For your information we can do it through UI with the help Site Actions / Manage Content and Structure.But i want to automate it using client side code.Server side code is restricted.
    or can we create a template of an existing page with content without the help of sharepoint designer.
    Thanks in advance
    with regards Ravichandra

    This is good example
    http://balajiindia.wordpress.com/2011/05/27/using-jquery-with-custom-web-services-in-sharepoint/
    Create web service
    http://balajiindia.wordpress.com/2011/05/27/using-jquery-with-custom-web-services-in-sharepoint/. Create method "Create Page" http://www.learningsharepoint.com/2010/09/17/create-publishing-pages-sharepoint-2010-programmatically/
    Build your Java Script. You can use Content Editor Web Part if you want to avoid custom web part development http://www.codeproject.com/Articles/544538/JQuery-with-SharePoint
    Oleg

  • Trying to add a webpart to webpart page erroring

    I have a webpart which internally calls a webservice. When i try to add it to a webpart page i get below error.
    An error occurred while attempting to add the gallery item [Miscellaneous] AProject to the page. The error was: Microsoft.SharePoint.WebPartPages.WebPartPageUserException: The remote server returned an error: (500) Internal Server Error. ---> System.Net.WebException:
    The remote server returned an error: (500) Internal Server Error.    
     at System.Net.HttpWebRequest.GetResponse()    
     at Microsoft.SharePoint.Client.SPWebRequestExecutor.Execute()    
     at Microsoft.SharePoint.Client.ClientRequest.ExecuteQueryToServer(ChunkStringBuilder sb)    
     at Siemens.Energy.MSPDB.Custom.AddNewProject.AddNewProject.Page_Load(Object sender, EventArgs e)    
     at System.Web.UI.Control.LoadRecursive()    
     at System.Web.UI.Control.AddedControl(Control control, Int32 index)    
     at System.Web.UI.WebControls.WebParts.WebPartManager.WebPartManagerControlCollection.AddWebPartHelper(WebPart webPart)    
     at System.Web.UI.WebControls.WebParts.WebPartManager.WebPartManagerControlCollection.AddWebPart(WebPart webPart)    
     at Microsoft.SharePoint.WebPartPages.SPWebPartManager.AddWebPartWithRetry(WebPart webPart)    
     at Microsoft.SharePoint.WebPartPages.SPWebPartManager.AddWebPartInternal(SPSupersetWebPart superset, Boolean throwIfLocked)     -
     -- End of inner exception stack trace ---    
     at Microsoft.SharePoint.WebPartPages.SPWebPartManager.AddWebPartInternal(SPSupersetWebPart superset, Boolean throwIfLocked)    
     at Microsoft.SharePoint.WebPartPages.WebPartGallerySourceBase.AddItemToPage(WebPartZoneBase zone, Int32 zoneIndex, WebPart webPart)    
     at Microsoft.SharePoint.WebPartPages.WebPartGallerySourceBase.AddItemToPage(WebPartZoneBase zone, Int32 zoneIndex, WebPartGalleryItem item, String wpid)    
     at Microsoft.SharePoint.WebPartPages.WebPartAdder.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument)

    Hi Yogendra,
    Does your account has permission to call the WebService ? May be your webpart trying to show or bind the data from the Webservice which is not available to your webpart.
    Try to access the webservice in browser using your account and check the progress.
    Fiddler is the best friend and also suggest you to call webservice method inside the SPMonitoredScope block. 
    Murugesa Pandian | MCPD | MCTS | SharePoint 2010

  • Cannot view SharePoint 2013 WebPart Page in Html iframe

    I would like to use html iframe for display sharepoint 2013 webpage page , it return following error :
    "This content cannot be displayed in a frame"
    Here is my code:
    <iframe width="100%" src="http://xxxx-dev-int:6346/Test/SitePages/wpSPFolderControl.aspx"> </iframe>
    i try to follow
    http://blogs.msdn.com/b/officeapps/archive/2012/12/12/iframing-sharepoint-hosted-pages-in-apps.aspx , but another error message shown
    "The Visible property cannot be set on Web Part 'g_5bf75035_be44_437a_8752_6360297f3f13'.  It can only be set on a standalone Web Part."
    The webpart page is correct , that can browse directly.
    Working environment:
    - SharePoint 2013
    - Windows Server 2012
    - Visual Studio Professional 2012
    - .Net framework 3.5
    Thanks for your help

    TRY
    <WebPartPages:AllowFraming ID="AllowFraming1" runat="server" />
    http://msdn.microsoft.com/en-us/library/office/fp179921(v=office.15).aspx
    http://blogs.msdn.com/b/officeapps/archive/2012/12/12/iframing-sharepoint-hosted-pages-in-apps.aspx
    or
    http://social.msdn.microsoft.com/Forums/en-US/fa6abb31-7251-4744-ab14-634cde38a42d/error-when-viewing-apps-that-utilize-webparts-this-content-cannot-be-displayed-in-a-frame?forum=appsforsharepoint
    <WebPartPages:AllowFramingID="AllowFraming1"runat="server"/>

  • How to remove/hide webpart page title

    I have a team site.  All pages are stored in Site Pages.  I added a webpart page called test1.  When I go to the page, I see "test1" to the right of the site icon on the top left side of the page.  How can I remove it or hide
    it?  I read somewhere that I should go to the document library that holds this page and under properties, edit webpart in maintenence view and make sure that "Webpart page title bar" in the column Open on Page says "No".  I did
    that and the name of the page still shows up. 
    Also, why is it that when I create a new webpart page I can only enter the value for "Name"?  Where do I go to enter the value for "Title" if I want the title of the page to be different than the file name (i.e. what shows up in
    the URL)?
    thanks,

    hi,
    You can set the WebPart cromeType to the below following values.
    to have no titel it set it to None or Border only.
    BorderOnly A border only, without a title bar.
    Default A border setting inherited from the part control's containing zone.
    None No border and no title bar.
    TitleAndBorder A title bar and a border.
    TitleOnly A title bar only, without a border.
    Member name
    Description
    BorderOnly
    A border only, without a title bar.
    Default
    A border setting inherited from the part control's containing zone.
    None
    No border and no title bar.
    TitleAndBorder
    A title bar and a border.
    TitleOnly
    A title bar only, without a border.
    Member name
    Description
    BorderOnly
    A border only, without a title bar.
    Default
    A border setting inherited from the part control's containing zone.
    None
    No border and no title bar.
    TitleAndBorder
    A title bar and a border.
    TitleOnly
    A title bar only, without a border.
    Member name
    Description
    BorderOnly
    A border only, without a title bar.
    Default
    A border setting inherited from the part control's containing zone.
    None
    No border and no title bar.
    TitleAndBorder
    A title bar and a border.
    TitleOnly
    A title bar only, without a border.
    Whenever you see a reply and if you think is helpful,Vote As Helpful! And whenever you see a reply being an answer to the question of the thread, click Mark As Answer

  • Insert webpart zone in tabs in webpart page using sharepoint designer 2010

    Hi All,
    I am facing a problem , its looks very easy but i couldn't found any clue about this.
    i have created a webpart page, after this i have enable to view quick launch in this webpart page. then i have create a some tabs with reference to this site
    https://jqueryui.com/tabs/. but the problem is when i go to view my page in browser it take same height which is same as quick launch height. and in my diff scenario i have created tab using content editor web part then its working fine. but
    i need to create web part zone in these tabs that why i m not able to do this using content editor. so i am using designer only.
    i guess i am writing content in wrong content place holder or etc. please help me ...i have already lost my 2 days for this.
    FYI, please find the code which i used in webpart page using share point desinger.
    <asp:Content ContentPlaceHolderId="PlaceHolderPageTitle" runat="server">
    <SharePoint:ListItemProperty Property="BaseName" maxlength="40" runat="server"/>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderPageTitleInTitleArea" runat="server">
    <WebPartPages:WebPartZone runat="server" title="loc:TitleBar" id="TitleBar" AllowLayoutChange="false" AllowPersonalization="false"><ZoneTemplate>
    <WebPartPages:TitleBarWebPart runat="server" AllowEdit="True" AllowConnect="True" ConnectionID="00000000-0000-0000-0000-000000000000" Title="Web Part Page Title Bar" IsIncluded="True" Dir="Default"
    IsVisible="True" AllowMinimize="False" ExportControlledProperties="True" ZoneID="TitleBar" ID="g_14e08bcc_e32c_4759_80dc_34e124e6212f" HeaderTitle="abc1" AllowClose="False" FrameState="Normal"
    ExportMode="All" AllowRemove="False" AllowHide="True" SuppressWebPartChrome="False" DetailLink="" ChromeType="None" HelpLink="" MissingAssembly="Cannot import this Web Part." PartImageSmall=""
    HelpMode="Modeless" FrameType="None" AllowZoneChange="True" PartOrder="2" Description="" PartImageLarge="" IsIncludedFilter="" __MarkupType="vsattributemarkup" __WebPartId="{14E08BCC-E32C-4759-80DC-34E124E6212F}"
    WebPart="true" Height="" Width=""></WebPartPages:TitleBarWebPart>
    </ZoneTemplate></WebPartPages:WebPartZone>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderTitleAreaClass" runat="server">
    <style type="text/css">
    Div.ms-titleareaframe {
    height: 100%;
    .ms-pagetitleareaframe table {
    background: none;
      </style>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderAdditionalPageHead" runat="server">
    <meta name="GENERATOR" content="Microsoft SharePoint" />
    <meta name="ProgId" content="SharePoint.WebPartPage.Document" />
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta name="CollaborationServer" content="SharePoint Team Web Site" />
    <script type="text/javascript">
    // <![CDATA[
    var navBarHelpOverrideKey = "WSSEndUser";
    // ]]>
    </script>
    <%--<SharePoint:UIVersionedContent ID="WebPartPageHideQLStyles" UIVersion="4" runat="server">
    <ContentTemplate>
    <style type="text/css">
    body #s4-leftpanel {
    display:none;
    .s4-ca {
    margin-
    </style>
    </ContentTemplate>
    </SharePoint:UIVersionedContent>--%></asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderSearchArea" runat="server">
    <SharePoint:DelegateControl runat="server"
    ControlId="SmallSearchInputBox"/>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderLeftActions" runat="server">
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderPageDescription" runat="server">
    <SharePoint:ProjectProperty Property="Description" runat="server"/>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderBodyRightMargin" runat="server">
    <div height="100%" class="ms-pagemargin"><img src="/_layouts/images/blank.gif" width="10" height="1" alt="" /></div>
    </asp:Content>
    <%--<asp:Content ContentPlaceHolderId="PlaceHolderPageImage" runat="server"></asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderNavSpacer" runat="server"></asp:Content>--%>
    <%--<asp:Content ContentPlaceHolderId="PlaceHolderLeftNavBar" runat="server"></asp:Content>--%>
    <asp:Content ContentPlaceHolderId="PlaceHolderMain" runat="server">
    <html lang="en">
    <head>
    <meta name="WebPartPageExpansion" content="full" />
      <meta charset="utf-8">
      <title>jQuery UI Tabs - Default functionality</title>
      <link rel="stylesheet" href="http://code.jquery.com/ui/1.10.3/themes/smoothness/jquery-ui.css">
      <script src="http://code.jquery.com/jquery-1.9.1.js"></script>
      <script src="http://code.jquery.com/ui/1.10.3/jquery-ui.js"></script>
      <link rel="stylesheet" href="/resources/demos/style.css"><script>
      $(function() {
        $( "#tabs" ).tabs();
      </script></head><body><div id="tabs">
      <ul>
        <li><a href="#tabs-1">Bangalore 1</a></li>
        <li><a href="#tabs-2">Bangalore 2</a></li>
        <li><a href="#tabs-3">Bangalore</a></li>
        <li><a href="#tabs-4">Chennai 4</a></li>
          </ul>
    <table cellpadding="4" cellspacing="0" border="0" width="100%">
    <tr>
    <td><div id="tabs-1"> <%--id="_invisibleIfEmpty" name="_invisibleIfEmpty" valign="top" width="100%"> --%><WebPartPages:WebPartZone id="g_6958510ECBD74ABD8AA9F8E26B747B27"
    runat="server" title="Zone 13"><ZoneTemplate></ZoneTemplate></WebPartPages:WebPartZone><WebPartPages:WebPartZone id="g_FA3DDD09582A4C589559877B7169340D" runat="server" title="Zone 14"><ZoneTemplate></ZoneTemplate></WebPartPages:WebPartZone></div></td>
    </tr>
    <tr><td><div id="tabs-2">
    <WebPartPages:WebPartZone id="g_73928F4B9F484EE392EBCBA7D5ACF9FE" runat="server" title="Zone 1"><ZoneTemplate></ZoneTemplate></WebPartPages:WebPartZone>
    <WebPartPages:WebPartZone id="g_77B2328C81874FFB8034559174B450BF" runat="server" title="Zone 12"><ZoneTemplate></ZoneTemplate></WebPartPages:WebPartZone>
    </div></td></tr>
    Please help..if u need any other detail i ll provide you.. plz check the image after doing this the tabs take full range as quick launch.
    Thanks
    Vivek Singh Tomar

    You do not need to work on visual studio, you can create page layout form web and sharepoint designer. Page layouts are only available on publishing sites, you can modify page layout using sharepoint designer, add your required html and web part zones.
    Check below few links for reference:
    http://msdn.microsoft.com/en-us/library/gg430141(v=office.14).aspx#bk_custompagelayout
    http://www.mssharepointtips.com/tip.asp?id=1125
    http://blogs.technet.com/b/tothesharepoint/archive/2013/04/10/stage-7-upload-page-layouts-and-create-new-pages-in-a-publishing-site.aspx
    http://msdn.microsoft.com/en-us/library/gg430141(v=office.14).aspx#bk_custompagelayout
    Page layouts creation and editing is almost same in MOSS 2007, SharePoint 2010 and SharePoint 2013. If you are creating page layout using web then you can easily modify it using SharePoint designer.
    Adnan Amin MCT, SharePoint Architect | If you find this post useful kindly please mark it as an answer :)

  • External List Webpart does not render after webpart page is checked in

    Hello,
    I've created an external list based on an external content type the list renders fine.
    I have in turn created a webpart page and added the external list to the webpart page as well as a current user filter.
    I use the filter to filter this list based on a column (username in the external list). I do all this within a publishing site (I don't know if that's contributing to the challenge I'm having).
    before I check in and publish the page I observe the filters are applied
    and it appears everything is ok. However after I check in the page and publish it the page doesn't render and the gears cycles on the page for ages
    It's worked the first time I did it but I had to delete and recreate the page subsequently the page doesn't render and gears animation just keeps playing. Even with the filter disconnected from the webpart it still doesn't render. What could kindly be the
    problem
    thanks

    Hi,
    As I understand, you encountered the issue when you checked in and published the web part page.
    If you do not have to use external list web part, you can change to use business data list web part in the business data. You can edit the web part and choose the external content type you want
    to connect.
    There is a similar case:
    https://social.technet.microsoft.com/Forums/sharepoint/en-US/af76e3fd-99f8-4694-bae6-e9ee53d2e66e/external-list-in-publishing-page?forum=sharepointgeneral
    Best regards
    Sara Fan
    TechNet Community Support

  • The webpage declined to show this webpage when WebPart Page is loaded

    I have a webpart page when I try to open that page I'm getting. The webpage declined to show this webpage.It loaded when the part was added to the page first time.But when I redeployed the WSP I'm getting this error.
    Please help me in this.
    Thanks & Regards,
    Mathi.
    With Regards, Mathi.

    Hi,
    According to your post, my understanding is that the webpage declined to show this webpage when WebPart Page was loaded.
    The problem was within the web part page. A web part was causing the page to 403. Some configuration to the web part had made the web part no longer permissible to show to the user. Instead of just not showing the web part, SharePoint declines to show the
    web part page.
    To resolve the problem, go to the Web Part Page Maintenance page for the page that is giving the 403 error:
    http://ServerName/SiteName/_layouts/spcontnt.aspx?&url=%2fSiteName%2fPages%2fPageName.aspx
    One by one disable the web parts. One of them is the problem. When it is disabled, the page will display properly to the user.
    You’d better to delete the web part and re-add it.
    There is an article for your reference, although it is about the SharePoint 2007, it still works for SharePoint 2010.
    http://dlairman.wordpress.com/2010/10/12/error-the-website-declined-to-show-this-webpage-http-403/
    Best Regards,
    Linda Li
    Linda Li
    TechNet Community Support

  • Cloning/Moving webpart pages with existing webparts

    Hi All,       
            We need to support clone/move of the webpart pages with pre populated webparts. We have our custom webpart page layout. Users can create webpart page using our custom page layout and can add webparts init. On cloning
    of the webpart page we just read the file(webpart page) from the document libary and saving it with different name in the same document library. But the cloned page does not retain the webparts added to it. The user can view only the empty webpart page layout.
    Please suggest me how to move/clone the webpart page with the existing webparts.
    Thanks,
    R.Prakash

    Hi Florin,
                Thanks a lot for your help.
                Based on your suggestion we completed the cloning of the WebPart pages.
    Code snippet:
    SPSecurity.RunWithElevatedPrivileges(delegate()
                    using (SPSite site = new SPSite(SPContext.Current.Site.ID))
                        using (SPWeb web = site.OpenWeb())
                            SPLimitedWebPartCollection lstWebPart = null;
                            web.AllowUnsafeUpdates = true;
                            using (SPLimitedWebPartManager webPartManager =
                                        SPContext.Current.Web.GetLimitedWebPartManager("Pages/BaseWebPartPage.aspx, 
    PersonalizationScope.Shared))
                                lstWebPart = webPartManager.WebParts;
                            using (SPLimitedWebPartManager webPartManager =
                                         SPContext.Current.Web.GetLimitedWebPartManager("Pages/ClonedWebPartPage.aspx, PersonalizationScope.Shared))
                                foreach (WebPart webPart in lstWebPart)
        webPartManager.AddWebPart(webPart, webPart.Zone.Id, webPart.ZoneIndex);
                                    web.Update();
                            web.AllowUnsafeUpdates = false;
    Thanks,
    R.Prakash

  • How to add the Note board web part to a page with powershell

    Hi everyone,
    I've been looking around everywhere but haven't seen it explicitly mentioned. 
    Does anyone know how to add the Note Board web part to a Team Site page, e.g. Non-publishing site, Left Zone, First webpart in the zone in powershell?
    Examples like this one http://adicodes.com/adding-web-part-to-page-with-powershell/ only talk about custom web parts uploaded from a local drive.
    The example here looks good - http://spcrew.com/blogs/lists/posts/post.aspx?id=21 but is it for the Page Viewer Web Part. How would you go about getting the correct name for the note board web part and configuring it? 
    Many Thanks,
    Ashley
    function main(){
    [void][System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint")
    $url = "http://sp2010dev1/sites/test1"
    $OpenWeb = Get-SPWeb $url
    $OpenWeb
    $OpenSite = Get-SPSite $url
    $file = $OpenWeb.GetFile("http://sp2010dev1/sites/test1/SitePages/test1.aspx")
    $WebPartManager = $file.GetLimitedWebPartManager([System.Web.UI.WebControls.WebParts.PersonalizationScope]::Shared)
    Add-PageViewerWebPart "http://sp2010dev1/sites/test1" "http://sp2010dev1/sites/test1/SitePages/test1.aspx" "Body" 0 "SPCrew Site" "sp2010dev"
    $OpenWeb.Dispose()
    function Add-PageViewerWebPart($SiteURL, $pageUrl, $webpartzone, $index, $title, $content)
        $site = new-object Microsoft.SharePoint.SPSite($SiteURL)
        $web=$site.OpenWeb()
        $webpartmanager=$web.GetLimitedWebPartManager($pageUrl, [System.Web.UI.WebControls.WebParts.PersonalizationScope]::Shared)
        $webpart = new-object Microsoft.SharePoint.WebPartPages.PageViewerWebPart
        $webpart.ChromeType = [System.Web.UI.WebControls.WebParts.PartChromeType]::TitleOnly;
        $webpart.Title = $title
        $webpart.ContentLink = "http://www.spcrew.com";
        $webpartmanager.AddWebPart($webpart, $webpartzone, $index);    
        $web.Close()
        $site.Close()
    function Get-SPSite([string]$url) {
        New-Object Microsoft.SharePoint.SPSite($url)
    function Get-SPWeb([string]$url) {
        $SPSite = Get-SPSite $url
        return $SPSite.OpenWeb()
        $SPSite.Dispose()

    Hi,
    According to your post, my understanding is that you wanted to add the Note board web part to a page with PowerShell.
    The name of the Note Board web part is SocialCommentWebPart.
    I recommend to use the powershell code below:
    $pageUrl="http://sitename/SitePages/test.aspx"
    $SiteURL="http://sitename"
    $site = new-object Microsoft.SharePoint.SPSite($SiteURL)
    $web=$site.OpenWeb()
    $webpartmanager=$web.GetLimitedWebPartManager($pageUrl, [System.Web.UI.WebControls.WebParts.PersonalizationScope]::Shared)
    $webpart = new-object Microsoft.SharePoint.Portal.WebControls.SocialCommentWebPart
    $webpart.title="Note Board"
    $webpartmanager.AddWebPart($webpart, "MiddleZone", 0);
    $web.Close()
    Then the Note board web part will be added to the page.
    Best Regards,
    Linda Li
    Linda Li
    TechNet Community Support

  • Passing multiple values to another page via a sql report

    Having trouble passing multiple values to another page via a popup SQL report
    I have two fields one called "descr" and another called "Met"
    when I use the code below all works fine and the value of "descr" is passed
    Select '&lt;a href="javascript:popUp2('''
    || 'f?p=&APP_ID.:950:&SESSION.::&DEBUG.::'
    || 'P950_TYPE:'
    || descr
    || ''', 790, 460);"style="color:darkred; font-weight: bold;font-size: 90%"&gt;'
    || descr
    || '&lt;/a&gt;' "Note"
    But when I want to pass another value, all goes bonkers and instead of the value of the field being passed the literal text is passed.
    can someone look at my code below and see what may be wrong
    Select '&lt;a href="javascript:popUp2('''
    || 'f?p=&APP_ID.:950:&SESSION.::&DEBUG.::'
    || 'P950_TYPE,P950_CODE:'
    || descr, Met
    || ''', 790, 460);"style="color:darkred; font-weight: bold;font-size: 90%"&gt;'
    || descr
    || '&lt;/a&gt;' "Note"
    I appeciate your help looking into this
    FYI (Here is the entire SQL for reference)
    With t
    as
    (SELECT
    CASE WHEN KEY = 2 then
    CASE WHEN WCS_CPT &gt; :P940_METRIC_1_WCS_CPT1 then
    '&lt;span style="color:Red; "&gt;'||TO_CHAR(WCS_CPT,'FML999G999G999G999G990D00')||'&lt;/span&gt;' else
    '&lt;span style="color:#399304; "&gt;'||TO_CHAR(WCS_CPT,'FML999G999G999G999G990D00')||'&lt;/span&gt;' end
    else '&lt;span style="color:#180c8b;"&gt;'||TO_CHAR(WCS_CPT,'FML999G999G999G999G990D00')||'&lt;/span&gt;' end "WCSCPT",
    CASE WHEN KEY = 2 then
    CASE WHEN WCS_TOI_PER_FTE &lt; :P940_METRIC_2_WCS_TOI_PER_FTE then
    '&lt;span style="color:Red; "&gt;'||TO_CHAR(WCS_TOI_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' else
    '&lt;span style="color:#399304; "&gt;'||TO_CHAR(WCS_TOI_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end
    else '&lt;span style="color:#180c8b;"&gt;'||TO_CHAR(WCS_TOI_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end "WCSTOIPERFTE",
    CASE WHEN KEY = 2 then
    CASE WHEN WCS_SIO_PER_FTE &lt; :P940_METRIC_3_WCS_SIO_PER_FTE then
    '&lt;span style="color:Red; "&gt;'||TO_CHAR(WCS_SIO_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' else
    '&lt;span style="color:#399304; "&gt;'||TO_CHAR(WCS_SIO_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end
    else '&lt;span style="color:#180c8b;"&gt;'||TO_CHAR(WCS_SIO_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end "WCSSIOPERFTE",
    CASE WHEN KEY = 2 then
    CASE WHEN WCS_TC_PER_FTE &lt; :P940_METRIC_4_WCS_TC_PER_FTE then
    '&lt;span style="color:Red; "&gt;'||TO_CHAR(WCS_TC_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' else
    '&lt;span style="color:#399304; "&gt;'||TO_CHAR(WCS_TC_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end
    else '&lt;span style="color:#180c8b;"&gt;'||TO_CHAR(WCS_TC_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end "WCSTCPERFTE",
    CASE WHEN KEY = 2 then
    CASE WHEN WCS_ADSL_PER_FTE &lt; :P940_METRIC_5_WCS_DSL_PER_FTE then
    '&lt;span style="color:Red; "&gt;'||TO_CHAR(WCS_ADSL_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' else
    '&lt;span style="color:#399304; "&gt;'||TO_CHAR(WCS_ADSL_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end
    else '&lt;span style="color:#180c8b;"&gt;'||TO_CHAR(WCS_ADSL_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end "WCSADSLPERFTE",
    CASE WHEN KEY = 2 THEN
    TO_CHAR(MONTH,'MON-YY')
    else
    'METRICS'
    end "MONTH"
    FROM (
    SELECT DISTINCT
    ROW_NUMBER() OVER (ORDER BY KEY DESC) AS ROW_NUM, KEY, WCS_CPT, WCS_TOI_PER_FTE, WCS_SIO_PER_FTE, WCS_TC_PER_FTE, WCS_ADSL_PER_FTE, MONTH
    from TW_M_KEYMETRICS
    WHERE TO_DATE(UPPER(MONTH),'DD/MON/YY') &gt;= TO_DATE(UPPER(:P940_START_OF_THIS_FIN_YEAR),'DD/MON/YY')
    ORDER BY KEY ASC, ROW_NUM, MONTH)
    WHERE ROW_NUM &lt;= :P940_MONTHS_SINCE_FIN_START)
    Select '&lt;a href="javascript:popUp2('''
    || 'f?p=&APP_ID.:950:&SESSION.::&DEBUG.::'
    || 'P950_METRIC_TYPE,P950_METRIC_VALUE:descr,MET'
    || ''
    || ''', 790, 460);"style="color:darkred; font-weight: bold;font-size: 90%"&gt;'
    || descr
    || '&lt;/a&gt;' "Note"
    , max(Met) METRICS, max(Jul) Jul08, max(Aug) Aug08, max(Sep) Sep08, max(Oct) Oct08, max(Nov) Nov08, max(Dec)Dec08, max(Jan) Jan08, max(Feb) Feb08, max(Mar) Mar08, max(Apr) Apr08, max(May) May08, max(Jun) Jun08
    from (
    Select 'Cost Per Transaction' descr,
    decode (MONTH, 'METRICS', WCSCPT) MET,
    decode (MONTH, 'JUL-08', WCSCPT) Jul,
    decode (MONTH, 'AUG-08', WCSCPT) Aug,
    decode (MONTH, 'SEP-08', WCSCPT) Sep,
    decode (MONTH, 'OCT-08', WCSCPT) Oct,
    decode (MONTH, 'NOV-08', WCSCPT) Nov,
    decode (MONTH, 'DEC-08', WCSCPT) Dec,
    decode (MONTH, 'JAN-08', WCSCPT) Jan,
    decode (MONTH, 'FEB-08', WCSCPT) Feb,
    decode (MONTH, 'MAR-08', WCSCPT) Mar,
    decode (MONTH, 'APR-08', WCSCPT) Apr,
    decode (MONTH, 'MAY-08', WCSCPT) May,
    decode (MONTH, 'JUN-08', WCSCPT) Jun
    from t
    union all
    Select 'Total Orders Issued Per FTE' descr,
    decode (MONTH, 'METRICS', WCSTOIPERFTE) MET,
    decode (MONTH, 'JUL-08', WCSTOIPERFTE) Jul,
    decode (MONTH, 'AUG-08', WCSTOIPERFTE) Aug,
    decode (MONTH, 'SEP-08', WCSTOIPERFTE) Sep,
    decode (MONTH, 'OCT-08', WCSTOIPERFTE) Oct,
    decode (MONTH, 'NOV-08', WCSTOIPERFTE) Nov,
    decode (MONTH, 'DEC-08', WCSTOIPERFTE) Dec,
    decode (MONTH, 'JAN-08', WCSTOIPERFTE) Jan,
    decode (MONTH, 'FEB-08', WCSTOIPERFTE) Feb,
    decode (MONTH, 'MAR-08', WCSTOIPERFTE) Mar,
    decode (MONTH, 'APR-08', WCSTOIPERFTE) Apr,
    decode (MONTH, 'MAY-08', WCSTOIPERFTE) May,
    decode (MONTH, 'JUN-08', WCSTOIPERFTE) Jun
    from t
    union all
    Select 'SIOs Per Billing FTE' descr,
    decode (MONTH, 'METRICS', WCSSIOPERFTE) MET,
    decode (MONTH, 'JUL-08', WCSSIOPERFTE) Jul,
    decode (MONTH, 'AUG-08', WCSSIOPERFTE) Aug,
    decode (MONTH, 'SEP-08', WCSSIOPERFTE) Sep,
    decode (MONTH, 'OCT-08', WCSSIOPERFTE) Oct,
    decode (MONTH, 'NOV-08', WCSSIOPERFTE) Nov,
    decode (MONTH, 'DEC-08', WCSSIOPERFTE) Dec,
    decode (MONTH, 'JAN-08', WCSSIOPERFTE) Jan,
    decode (MONTH, 'FEB-08', WCSSIOPERFTE) Feb,
    decode (MONTH, 'MAR-08', WCSSIOPERFTE) Mar,
    decode (MONTH, 'APR-08', WCSSIOPERFTE) Apr,
    decode (MONTH, 'MAY-08', WCSSIOPERFTE) May,
    decode (MONTH, 'JUN-08', WCSSIOPERFTE) Jun
    from t
    union all
    Select 'Total Calls Answered per FTE' descr,
    decode (MONTH, 'METRICS', WCSTCPERFTE) MET,
    decode (MONTH, 'JUL-08', WCSTCPERFTE) Jul,
    decode (MONTH, 'AUG-08', WCSTCPERFTE) Aug,
    decode (MONTH, 'SEP-08', WCSTCPERFTE) Sep,
    decode (MONTH, 'OCT-08', WCSTCPERFTE) Oct,
    decode (MONTH, 'NOV-08', WCSTCPERFTE) Nov,
    decode (MONTH, 'DEC-08', WCSTCPERFTE) Dec,
    decode (MONTH, 'JAN-08', WCSTCPERFTE) Jan,
    decode (MONTH, 'FEB-08', WCSTCPERFTE) Feb,
    decode (MONTH, 'MAR-08', WCSTCPERFTE) Mar,
    decode (MONTH, 'APR-08', WCSTCPERFTE) Apr,
    decode (MONTH, 'MAY-08', WCSTCPERFTE) May,
    decode (MONTH, 'JUN-08', WCSTCPERFTE) Jun
    from t
    union all
    Select 'ADSL Orders per FTE' descr,
    decode (MONTH, 'METRICS', WCSADSLPERFTE) MET,
    decode (MONTH, 'JUL-08', WCSADSLPERFTE) Jul,
    decode (MONTH, 'AUG-08', WCSADSLPERFTE) Aug,
    decode (MONTH, 'SEP-08', WCSADSLPERFTE) Sep,
    decode (MONTH, 'OCT-08', WCSADSLPERFTE) Oct,
    decode (MONTH, 'NOV-08', WCSADSLPERFTE) Nov,
    decode (MONTH, 'DEC-08', WCSADSLPERFTE) Dec,
    decode (MONTH, 'JAN-08', WCSADSLPERFTE) Jan,
    decode (MONTH, 'FEB-08', WCSADSLPERFTE) Feb,
    decode (MONTH, 'MAR-08', WCSADSLPERFTE) Mar,
    decode (MONTH, 'APR-08', WCSADSLPERFTE) Apr,
    decode (MONTH, 'MAY-08', WCSADSLPERFTE) May,
    decode (MONTH, 'JUN-08', WCSADSLPERFTE) Jun
    from t
    GROUP by descr
    Frank

    Borg Species 5618 wrote:
    Having trouble passing multiple values to another page via a popup SQL report
    But when I want to pass another value, all goes bonkers and instead of the value of the field being passed the literal text is passed.
    can someone look at my code below and see what may be wrong
    Select '&lt;a href="javascript:popUp2('''
    || 'f?p=&APP_ID.:950:&SESSION.::&DEBUG.::'
    || 'P950_TYPE,P950_CODE:'
    || descr, Met
    || ''', 790, 460);"style="color:darkred; font-weight: bold;font-size: 90%"&gt;'
    || descr
    || '&lt;/a&gt;' "Note"
    Hi Frank,
    You should close this parameters with single quotation. Try this -
    Select '&lt;a href="javascript:popUp2('''
    || 'f?p=&APP_ID.:950:&SESSION.::&DEBUG.::'
    || 'P950_TYPE,P950_CODE:'
    *|| 'descr, Met'*
    || ''', 790, 460);"style="color:darkred; font-weight: bold;font-size: 90%"&gt;'
    || descr
    || '&lt;/a&gt;' "Note"
    Hope this helps.
    Regards,
    M Tajuddin
    http://tajuddin.whitepagesbd.com

  • Why can't I print a document created on my MacBook Air with Pages via a wired Lexmark X2650 printer?

    I am unable to printe a document I created on my Mac with Pages via a wired Lexmark X2650 printer. Of course, I have already confirmed that it is correctly set up and connected. Why?
    Thank you.
    <Email Edited by Host>

    TextEdit is an application on your Mac.
    Type TextEdit into Spotlight (magnifying icon top right on the menubar) to quickly locate and open it.
    It is the basic Text/Word Processor (but actually very capable) that comes with all Macs and a good place to test differences if you hit a problem.
    Peter

Maybe you are looking for

  • 2011 Macbook Pro 17" reviews

    Hello all, Thanks to a little family mix-up, I may be needing to upgrade myself to a new notebook this year. I've been looking, and I'm going to grab a computer that will last me for a good while. I work with a lot of ad design/ video editing tasks a

  • How to create a time column

    hi all i have a table to define the users i want to add a new two columns that define the time which the user can login in that time defined in the table of the user and every time the user login , it will check the login time with the time interval

  • Any way to restore from a back up; old software to new?

    I lost my iPhone 4 a few months ago and got a 3gs off my manager. The problem is he had already updated to software version 5 and when I had my iPhone 4 backed up it was using 4.3.3. So i cannot restore from back-up as they are not compatable. I have

  • Invoice in EDI format

    A customer of my company wants us to send invoices in 810 EDI format from SAP. Does any one know how to do the necessary set ups/configuration in SAP to send the invoice IDoc? Points rewarded for helpful answers. Thanks, Archana

  • PIDX successful/unsuccessful implementations

    Hi, I am looking for inputs on PIDX. It would be great if you can provide me the contact  e-mail of the following ppl who have made an attempt to implment PIDX using SAP XI. <b>Amjad-Ali Khoja  from accenture</b> Using RNIF adapter 2.0 with PIDX v1.0