Thursday, May 10, 2012

[sharepointdiscussions] Digest Number 4442

Messages In This Digest (3 Messages)

Messages

1a.

Re: Snippet for Powershell to Add a Page-Viewer Web Part

Posted by: "brother.gabriel" brgabriel@sspx.org   brother.gabriel

Tue May 8, 2012 5:43 pm (PDT)



Mr. Hahner, that is simply fabulous! I don't think I have ever had anyone blog something for me before! On the page, are you the fellow on the left or the right? As soon as I am able to try it out, I will let you know how it goes for me. Thanks a bushel for that, and God bless you!

--- In sharepointdiscussions@yahoogroups.com, "sethhahner" <sethhahner@...> wrote:
>
> Hello Brother Gabriel!
>
> I just blogged this one for you!
> http://spcrew.com/blogs/lists/posts/post.aspx?id=21
>
> The main part of the code is this:
> 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
>
> $docXml = New-Object System.Xml.XmlDocument
> $contentXml = $docXml.CreateElement("ContentLink");
> $contentXml.set_InnerText("http://spcrew.com");
> $docXml.AppendChild($contentXml);
> $webpart.ContentLink = "http://www.spcrew.com";
> $webpartmanager.AddWebPart($webpart, $webpartzone, $index);
>
> $web.Close()
> $site.Close()
> }
>
>
>
> ENJOY!!
>
> --- In sharepointdiscussions@yahoogroups.com, "brother.gabriel" <brgabriel@> wrote:
> >
> > Salvete! Does anyone have a powershell snippet for adding a page-viewer web part? Or does anyone know of a link where I can get the details for writing one? I am not sure where to look. Google knows too much, but not enough.
> >
>

2a.

How to remove ECB menu item of a sharepoint list ?

Posted by: "Aneesh K K" kkaneesh@rocketmail.com   kkaneesh@rocketmail.com

Wed May 9, 2012 5:52 am (PDT)



How to remove ECB menu item of a sharepoint list ? I want to remove "Edit Item" and "Workflows" from a particular list view. i.e, from an aspx page only.
Thank in advance

2b.

Re: How to remove ECB menu item of a sharepoint list ?

Posted by: "Peter Brunone" peter.brunone@gmail.com   peter_brunone

Wed May 9, 2012 6:48 am (PDT)



Do you want them hidden, or just disabled?

On Wed, May 9, 2012 at 3:31 AM, Aneesh K K <kkaneesh@rocketmail.com> wrote:

> How to remove ECB menu item of a sharepoint list ? I want to remove "Edit
> Item" and "Workflows" from a particular list view. i.e, from an aspx page
> only.
> Thank in advance
>
>
>

[Non-text portions of this message have been removed]

Recent Activity
Visit Your Group
Yahoo! Groups

Cats Group

Join a group for

cat owners like you

New business?

Get new customers.

List your web site

in Yahoo! Search.

Y! Messenger

Want a quick chat?

Chat over IM with

group members.

Need to Reply?

Click one of the "Reply" links to respond to a specific message in the Daily Digest.

Create New Topic | Visit Your Group on the Web

No comments: