Posts

Showing posts from July, 2009

Customize content query web part title link to redirect to source after pressing close on detail button

I observed that whenever we use content query web part and try to browse for the list detail page. It will come back to View All page of list instead of going back to where it was coming from. I resolved it by doing following small changes in XSL style of content query web part to fix this as per my requirement and making it consistent with other list options. Create custom style Please refer my earlier post "How to add a new indicator in a Content Query Web Part" for details of customization and before following these step 1. Edit ItemStyle.xl 2. Add following name space at the to xmlns:ddwrt=”http://schemas.microsoft.com/WebParts/v2/DataView/runtime” 3. Add <xsl:param name=”PageUrl” /> just after name space declarations. This will define a variable Page URL and populate it with current page URL 4. In your custom template add following line before processing of title <xsl:variable name=”CustomPageLink” select=”concat($SafeLinkUrl,’&amp;Source=’,$PageUrl)” />

Issues in sending MOSS Alert from Document Library

Working with MOSS is great but sometime its make you crazy for small issues. That happens to me......... I was working with document library and adding alerts on document for notification from MOSS whenever any new document get inserted in the system. I realize that few of my alerts were not working. i.e. I get the initial email from Sharepoint application telling me that you have subscribed for alerts but when I did insertion nothing comes up in my inbox. I did lot of searching on internet but didn't find anything related to my issue. I have verified that my timer service was properly scheduled and running and my user has proper rights on document library. After sometime I realize that my alerts were working fine with normal document library but were behaving abnormally when I try to us custom content type. So I remove required alert and add a new alert for all type of changes!!!!!!!!!!!!!!!!!!!!!!!!!!!! and suddenly I get flooded with alerts in my alerts. Now I understand issue.

How to add a new indicator in a Content Query Web Part

Content Query web part doesn't show New! status indicator for new items by default. In order to add new indicator a customization of content query web part will be required. Following steps define the process for adding new container 1. Open SharePoint Designer and connect to your site 2. Browse to following path from SharePoint Designer StyleLibrary->XSL Style Sheets->Item Style.xsl 3. Above xsl contains style templaes that can be selected from Content Query web part's properties. You need to implement your custom template. 4. Copy any suitable template that can become base for your custom style. I would prefer to copy default template 5. Paste template at the end of file before </xsl:stylesheet> end tag 6. Change name to your style name e.g. CustomStyle and match to custom style e.g. Row[@Style='CustomStyle'] 7. Need to add following declaration at top of the file with other declarations xmlns:ddwrt="http://schemas.microsoft.com/WebParts/v2/DataView/r

Issue in share point 2007 or MOSS menu selection

We have discovered an issue in share point / MOSS top navigation menu while associating menu headings with share point system pages like list details pages. Reproducing an issue is simple using following steps. 1. Go to your site 2. Select Site Action->Site Settings -> Modify All Site Settings 3. Select Navigation under Look n Feel section 4. Click on Add Heading 5. In Title write test 6. In URL select browse and browse to any list in your site e.g. /Documents/Forms/AllItems.aspx 7. Click ok 8. Go to home page of your site 9. Select top navigation menu created in step 4 10. You will find that your page will open but first menu item will remain selected in your top navigation menu We have noticed this issue while doing modification with system pages only. So workaround to this solution will be to create a separate page and use show pages list to display pages and hide any additional pages that you don’t want to display

STSAdm AddSolution - Failed to extract the cab file

Building and deploying solution in moss sometime throws error “Failed to extract the cab file” This issue generally occurs due to inconsistencies in your ddf file. Please check following for correction. 1. Open your ddf file and location duplicate entries. If found remove them 2. Open your ddf file and check if there is any entries present in ddf not included in your project. A simple way to check is by clicking on “show all files” button in “Solution Explorer” view of visual studio 2008 and check if any file exists in root file that is not included in a project (Files not included in project will not become part of your cab files). For such files either include them in project if required or delete them from folder.

Customizing Share point 2007/MOSS Top Navigation Bar/Menu Control (ASP Menu Control)

Customizing Share point 2007/MOSS Top Navigation Bar/Menu Control (ASP Menu Control) For customizing menu we have two options. 1. Write a custom control and embed it in Master Page 2. Customize existing share point menu control I believe that option 2 is better as compared to option 1. But you may face certain issues in implementing option 2. We have listed solutions for few issues in customization of share point menu using share point menu controls. Please note that following solution is based on assumption that solution will be for single level menu. Simple Customization using CSS If your customization is simple i.e. can be catered easily by applying CSS. Option2 will be fairly simple and can be implemented easily without any issues. In above case you have following options a) Modify existing CSS class. b) Create new CSS class and associate it with share point menu control In case you are using existing CSS class you don’t need to change anything in master page and need to do styli

Using content query web part

A Content Query Web Part displays a dynamic view of content on a page in your Microsoft Office SharePoint Server 2007 site. The Web Part runs a query that can span lists and sites in your site collection, and then presents the results of that query on the page. You can, for example, use this Web Part to display the five most recently published articles in your Web site, regardless of where they are stored. By default, the XSL style sheet that controls the presentation of the Content Query Web Part renders the Title, Description, ImageUrl, and LinkUrl columns (if present) of the items the query returns. The Web Part renders the ImageUrl and LinkUrl columns as an image and as a hyperlink, respectively. The Content Query Web Part uses XSL style sheets to render these columns by default. If you want to query for custom content types and render specific columns from those content types in the Web Part, you need to perform some minor customization in the .webpart file. Follow these steps in

Importing user profile from LDAP

MOSS provide out of box support for importing users from LDAP directory. You need to perform following steps in order to configure share point shared services provider to enable imports. 1. Open Central Administration site 2. Go to shared service provider link under shared service Administration link 3. Select User Profile and Properties under User Profile and My Site section 4. Select View Import connection 5. Click on create a new connection 6. Provide connection setting similar to that. Please note that example are for connecting your site with LDAP Server comes with domino server. a. Type: Select LDAP Directory b. Connection Name: Write name of your connection e.g. LotusLDAPCon c. Directory Server Name: Write IP Address of your LDAP Server or your Server name e.g. LOTUSSRV d. Port: Leave it to default i.e. 389 if your LDAP is deployed at custom port specify your port. e. Time Out: Specify time out or leave it to defaul

Sending alerts to group using Share point 2007/MOSS

Sending alerts to users are much easier and administrator can assign active directory user for dispatching emails. Please note that share point uses email address from user’s profile for dispatching emails. Therefore alert cannot be configured for user if email address is not associated in active directory account. Coming back to original points sending alerts to groups can be of two types. 1. Sending alert to AD Group 2. Sending alert to Share point Group For sending email to AD Group you need to make sure two things. 1. Group needs to be “email enabled security group”. As distribution lists are not supported in share point 2. You need to explicitly add group in permission setting in list/Document Library etc There is one limitation is that you cannot edit group and can only delete/recreate alert from Site Action->Site Setting ->User Alert (Site Administration) option For Sending email to Share point Group There is no out of box support for sending email alerts to share point gr

How to find internal column name of share point list’s column

Most of customizable feature such as Content Query Web Part require columns internal name for customization same is true for building CAML query. Following will help you in getting internal name of list’s column. 1. Open share point list setting 2. Right click on column and select properties 3. In Address URL field search for value of field (e.g. ….%7D&Field=Details) 4. Value of field represent internal name of share point list’s column.

Creating/Deploying simple farm for MOSS

Following post is really helpful for configuring simple farm environment on share point portal server 2007 or MOSS. I believe any novice person can start deployment reading this http://technet.microsoft.com/en-us/library/cc262243.aspx Following define a specific scenario deployment for share point server 2007 with three separate servers. 1. Database Server (SQL Database) 2. Share point Web Front End (Web server, Central Administration, Query Server) 3. Indexing Server (Indexing Server) Please follow these steps. 1. Install SQL Server on Database Server. 2. Install Share point Portal Server 2007 on Share point Web Front End with following consideration a. Select Advance option b. Select Complete in Server Type c. Do not run Share point Product and Technology Configuration Wizard 3. Install Share point Portal Server 2007 on Indexing Server with following consideration a. Select Advance option b. Select Complete in Server Ty

Configuring SMTP Service for routing emails to an external SMTP Server

Following are step for configuration of SMTP service for routing your email to an external SMTP Server. 1. Install SMTP Services from Add Remove Windows Component (This may require a windows CD) 2. Open IIS Admin (IIS Manager) Console from Administrative tools 3. Select Domains under Default SMTP Virtual Server 4. Right click and select new domain 5. Give name to your external domain 6. Got to properties setting of domain created in step 4 7. Check “Allow incoming mails to be relayed to this domain” 8. Select forward all emails to smart host and write local host in text box below 9. Select “Default SMTP Virtual Server” right click and select properties 10. Go to delivery tab and select advance option 11. Write your external SMTP server name e.g. smtp.yahoo.com or IP address e.g. [111.111.111.111] Note: Make sure to enclose IP address in square brackets 12. Go to Access tab and select Relay Restriction 13. Add IP address or

Using MOSS Out of box RSS Viewer Webpart

I was trying to use RSS Viewer web part and noticed lots of issues. I did a lot of searching over the web and finally managed to make it work for me. Thanks to fellows who have already published their finding. The first or general issue that can be found using RSS Feed Viewer web part is mentioned below "An unexpected error occured processing your request. Check the logs for details and correct the problem" There are many possibilities for this but the most common issue arise is related to configuration of proxy settings in your application web.config. As RSS Viewer use internet for downloading feed it requires proper proxy configuration for locating internet source. Similar is true for any custom application that requires data access from internet and is behind proxy. Following are steps to configure proxy settings. 1. Go to web application directory generally (C:\Inetpub\wwwroot\wss\VirtualDirectories\ ) 2. Edit web.config using proper text editor like notepad. (I used word

Backup and restoring MOSS site/sitecollection using stsadm

There are multiple ways for taking MOSS Site collection backups and restoring backups at later time. However it is recommended to backup/restore site collection using stsadm utility Following are command for backup/restore share point site collection using stsadm Backup Stsadm –o backup –url -filename Restore Stsadm –o restore –url -filename