Archive
Calculated Column Formula: Date Format #SP2010 #SharePoint #in
Just a reminder for me really… At a client at the moment who wants to put the date in list web parts in the following format: dd-MMM-yyyy.
I found the following article suggesting using the TEXT function in a Calculated Column
Formula Example:
Output:
09-Mar-2011
Useful findings whilst learning Reporting Services with #SP2010 #SharePoint #PS2010 #ProjectServer
So the first phase of the project I have been on for the last year is starting to move into the closing phases. The information architecture is in place, most of the custom development is complete and mapped to the project lifecycle / business processes of my client.
The project takes data from multiple places including:
- SAP (Resource, cost rate, metadata and product contract information)
- Project Server 2010 (Timesheets, Plans, Project / Task / Assignment data)
- SharePoint 2010 (Risks, Issues, Actions, Documents etc.)
- Custom database (Snapshot data)
I’ve learnt a lot about SharePoint 2010 and Project Server 2010 since I started this project (pre public beta). So now that we have all this data, the time has come to bring it all together with Business Intelligence dashboards and UI design.
Once of the main tools we are using for this is Reporting Services in SharePoint Integration mode and although I have lead projects involving SSRS in the past, actually getting my hands dirty and creating reports myself is something of a novelty.
However, time and resource pressures have meant that I have had to setup the SSRS infrastructure, development environments and test reports to ensure that the data can be utilised in the required way. As part of this setup I am also training my client on the business intelligence studio interface and deployment of reports in to SharePoint environment.
So getting to the point of this post, below is a list of useful links, findings and discoveries I have made during this setup process this week to serve as a reminder to me and will hopefully help others too.
Reporting Services Web Part – Firefox Compatibility (Windows, Linux – 3.6.13)
- Turn off Asynchronous data (Edit Web Part Settings > View Section)
NB: If this setting is left to its default, the loading screen does not go away until you hit the refresh button on the Web Part toolbar.
SharePoint Integration Mode – Linking to pages within SharePoint
It would appear that the Reporting Services web part in SP2010 disables links where the target URL is within SharePoint itself (“/pages/default.aspx” for example).
This blog post suggested a useful workaround:
However the suggested approach was good if you had a definitive URL such as default.aspx, but if you wanted to add a query string parameter based on the data returned, adding as action directly to the image did not allow me to select the appropriate date.
To get round this, I added a calculated field to the data set using the same process suggested in the post:
NB: Since working this out, I have extended it to use a standard JavaScript function that is running from the Master Page to make links in the reports more generic.
Then for the action on the image I was able to select “Go to URL” and select my calculated field.
This doesn’t work in the designer preview (or any exports of the report), however it works a treat when you are using the report as part of a dashboard with drill down features.
Interactive Column Sorting
Another useful blog post:
Although the instructions are for SSRS 2005, it is still relevant today.
- Right click on the column header field
- Select Properties
- Interactive Sort Tab
- Select the appropriate sort field
- Click OK
Alternating Row Colours
Always a popular choice for tabular based reports.
Highlight the data row and under the properties pane for the background color, use the following expression:
MSDN Documentation Links
- Support Features for SharePoint Integration Mode: http://msdn.microsoft.com/en-us/library/bb326290(v=SQL.100).aspx
- Reporting Services Features: http://msdn.microsoft.com/en-us/library/ms159273(v=SQL.100).aspx
- Tutorials: http://msdn.microsoft.com/en-us/library/bb522859(v=SQL.100).aspx
- Design Guidance: http://msdn.microsoft.com/en-us/library/ms159734(v=SQL.100).aspx
- Designing and Implementing Reports Using Report Designer: http://msdn.microsoft.com/en-us/library/ms159253(v=SQL.100).aspx
- Development Topics (High Level): http://msdn.microsoft.com/en-us/library/bb522683(v=SQL.100).aspx
- Report Builder Information: http://technet.microsoft.com/en-us/ff657833.aspx
- How to publish a report to a SharePoint Library: http://msdn.microsoft.com/en-us/library/bb283155.aspx
NB: Although a lot of the above links are for SSRS 2008, there is an option at the top of the page to make the content relevant for SSRS 2008 R2 also.
Useful JavaScript Function – Refreshing a page with parameters for use with Query String Filter Web Parts in #SP2010 #SharePoint #ProjectServer #PS2010 #in
In my current project I have the need to determine the current users personal preferences based on favourites stored in a list.
These personal preferences then drive various web parts on the page.
Using this the Enterprise Edition of SharePoint Server 2010 makes this very easy with the use of the Query String Filter Web Part and various other web parts that support connections including:
- Reporting Services Web Part
- Excel Services Web Part
- List Web Parts
- etc…
Using the combination of parameters and the above web parts it makes it a lot easier to create dashboard pages that are specific to a users:
- Preferences
- Job Role
- Department
- etc…
Now in most of my projects, I have found that dashboard pages tend to be buried under a 2nd or 3rd level of navigation, which makes it very easy to create links with parameters already in them.
However, in this case, I have to create various dashboard pages at the root of the site, whilst using standard SharePoint Publishing Navigation (Global Navigation). The parameters being passed are user selectable based on favourites stored in a list.
Given that the SharePoint Site Map Provider doesn’t know about this random favourites list I have created, I need to improvise to ensure that the end user is presented with dashboard pages personalised to them, as soon as they hit the root site URL.
Code Example:
Essentially the following happens:
- The page load to a certain point
- We determine if we have the query string parameter(s) we are looking for
- If we don’t, we stop the page from rendering using document.execCommand(“stop”)
- Go get our require parameter(s)
- Determine if any previous parameters existed on the page currently (to make the code more generic)
- Reload the page with the new parameter(s)
If you find any unwanted page flashing before the page reload, use JavaScript to set style=”display: none;” on the main content <div> on the v4.master – Master Page, if the parameter doesn’t exist.
Although this is certainly one method of achieving my goal and seems to currently fit my clients requirements, I would certainly be interested to hear from others on how to achieve my goal without drastically changing standard SharePoint components.
Useful JavaScript Function: isInteger and isNumeric #SharePoint #SP2010 #in
Just a quick post as a reminder for myself in future projects.
Working with Enterprise Custom Fields via VBA Macros in MS Project 2010 #MSProject #ProjectServer #SharePoint #SP2010 #in
As per my previous post, my colleagues and I are working on various customisations to the Microsoft Project 2010 client in our SharePoint 2010 / Project Server 2010 integration project for an international company.
Primarily my job is to architect and implement SharePoint solutions but recently I have been getting heavily involved in Project Server and Microsoft Project.
Yesterday and today I have been having to dust off my VBA skills to aid a colleague and wil the help of MSDN forums, we were able to come to a solution.
We found that when querying Enterprise Custom Task Fields from Project Server using the GetFields method, it would return them as a string value as it was shown in the client, regardless of the field type.
If you use the same GetFields method to query a local task field, it will be returned as expected in accordance to the field type.
For Example:
Client Setup Details: 1 Day = 8 Hours (480 Minutes)
Enterprise Custom Task Field
- Field Name: EnterpriseDurationTest
- Field Type: Duration
- Field Source: Enterprise Custom Task Field (Project Server)
- Value: 1 Day
- GetFields Method return: 1 Day
Local Custom Task Field
- Field Name: LocalDurationTest
- Field Type: Duration
- Field Source: Local Task Field (Microsoft Project)
- Value: 1 Day
- GetFields Method return: 480 (returned in minutes)
Now this make comparison quite hard unless you start splitting the string returned from the enterprise custom field and hard coding the number of hours that make up a day.
As a work around, Jan De Messemaeker (Project MVP), helped provide an answer:
By simply taking the output of the Enterprise Custom Task Field and placing it into a spare local field, it will do the appropriate conversion for us and we can the query the local field to to our comparison.
This blog post is simply here as a reminder for myself (future projects etc.) but also as a thank you to the growing Project Server and Microsoft Project community.
Useful details and links when rolling out Microsoft Project 2010 #PS2010 #ProjectServer #SharePoint #SP2010 #MSProject #in
In my current project where we are integrating SharePoint Server 2010 and Project Server 2010, we are starting to go into the details of rolling out the Microsoft Project 2010 client globally.
Some of the features we are implementing require VBA macros in MS Project 2010 which are brought down to the client application via the Enterprise Global Template from Project Server.
The following details and links have been useful during my investigations:
ADM Templates for Office 2010 – AD Policy Templates:
- Information: http://technet.microsoft.com/en-us/library/cc179176.aspx
- Download: http://www.microsoft.com/downloads/details.aspx?displaylang=en&FamilyID=64b837b6-0aa0-4c07-bc34-bec3990a7956
How to Digitally Sign a VBA Macro in Microsoft Project:
Registry Key to change:
- \\HKEY_CURRENT_USER\Software\Microsoft\Office\14.0\MS Project\Security\VBAWarnings
Registry Option Values:
- 1 = Enable all macros (not recommended; potentially dangerous code can run)
- 2 = Disable all macros except digitally signed macros
- 3 = Disable all macros with notification
- 4 = Disable all macros without notification
- NB: The text in the options match those available in the Trust Center in File > Options of the Microsoft Project 2010 Client.
Programmatically setting a field to hidden within a Content Type #SharePoint #SP2010 #in
At a client recently, my development colleague was struggling to find out how to set a field attached to a custom Content Type in a list to be hidden to aid in document management (so it is not shown in the Document Properties panel in Microsoft Word).
The following post seemed to suggest an unofficial way:
However, we try to keep things in a supported model if possible.
Through further looking he came across the following property:
- After further playing in code, he managed to crack it with the “.hidden” method.
- Code Example:
This code will set the Hidden flag (same as you can through the UI) against the document library. The above iterates through a List of strings which contains the fields i want to hide.
NB: Please not that this works because we are using our own content type attached to the library.
Creating Test / Filler / Example text from Microsoft Word #SharePoint #SP2010 #in ‘#MSOffice
I always forget the following link when I want some example text in my projects for Plain / Rich Text fields (in Lists and InfoPath Forms), Word Documents (Document Management etc.)
Microsoft Office Help Link: http://blogs.office.com/b/microsoft-word/archive/2009/05/12/quick-tip-filler-text.aspx
Quick Reference
Within Word type the following:
- =rand()
- =lorem()
These produce a single paragraph, but the function is configurable via the following parameters:
- =rand(insert the number of paragraphs, insert the number of sentences)
- =lorem(insert the number of paragraphs, insert the number of sentences)
Example: =lorem(1,6)
A reference / links to Creating Custom Actions in #SharePoint #SP2010 #in
Some good links that a colleague found about adding custom menu actions (ECB):
SharePoint 2007 Examples: http://www.customware.net/repository/pages/viewpage.action?pageId=69173255
SP2010 MSDN Article: http://msdn.microsoft.com/en-us/library/ms473643.aspx
WSS 3.0 / MOSS 2007 MSDN Article: http://msdn.microsoft.com/en-us/library/ms473643(v=office.12).aspx






You must be logged in to post a comment.