Kraft & Kennedy, Inc. provides technology and strategic consulting services to law firms, corporate legal departments and financial services firms. We can help you analyze, plan, implement and manage business and technology solutions to optimize your organization's functionality and processes.
Most of the information in an employee’s MySite profile comes from the Active Directory profile import, which is set up in the SharePoint Shared Service Provider. However, this can be tricky with employee photos since links to photos are not normally stored in Active Directory. An easy way around this if you don’t want to store the links in Active Directory, is to simply create a picture library in SharePoint and upload all of the employee photos to the picture library with a standard name, such as username.jpg. Then you can write a script to update each MySite profile and associate the photo with the person.
Continue reading…
Windows SharePoint Services (WSS) doesn’t come with a whole lot of web parts out of the box, but here’s a few handy ones we’ve found to spice up some of the home pages we’ve built. These are all free and work with WSS.
Only MOSS comes with an RSS reader, and even that one can display only one feed. This web part is invaluable if you’re using WSS. This is the best free RSS feed web part that I’ve found, and it allows you to neatly pull multiple feeds next to each other.
This web part neatly displays the weather in 3 cities side-by-side and can optionally display the time if they are in different time zones. This is a nice looking web part and tends to fit nicely on the right-hand side of a home page for a firm with multiple offices.
This web part displays stock quotes, company names, changes, and percent changes pulled from MSN Money. It’s the best free web part I’ve seen to do this, and will save a lot of time over trying to follow one of the examples online for doing this with a data view.
This uses the twitter search API to search twitter based on the parameters you specify in the web part, and you can download the wsp or the source code from the web page.
We’ve had a few instances where we were asked to put a Google search box on a SharePoint page. This can easily be accomplished by just inserting a content editor web part on the page and editing the HTML directly. You can paste in the following code, which includes JavaScript, to open a Google results page after the person enters a search term and presses enter or clicks a button. This is of course a simple approach–you could also federate search results in your search center to include Google–but this simple html code works well in many cases.
<P align=left>Search Google: <INPUT id=Google name=Google onkeydown="javascript:if (event.which || event.keyCode){if ((event.which == 13) || (event.keyCode == 13)) {
window.open('http://www.google.com/search?hl=en&q=' + this.value + '&btnG=Google+Search','_blank','');
return false;}};"> <IMG alt="Go" id="btnGo" name="btnGo" src="/images1/icongo.gif" onclick="window.open('http://www.google.com/search?hl=en&q=' + document.all.Google.value + '&btnG=Google+Search','_blank','')" onmouseover="this.style.cursor='hand'">
</P>
Research in Motion (RIM) offers two ways of writing applications for BlackBerry devices–Native Java, and the Microsoft Visual Studio plugin. As a VB.Net developer, I was tempted to go the Visual Studio plugin approach, but I decided against it for the following reasons:
For these reasons, to be able to debug for the Storm, and to have access to the entire BlackBerry library, I decided to go with the Java approach. The transition is quite easy, once you get the development environment in place and write your first test application. The BlackBerry website has a lot of good information for developers, if you’re able to find it.
I found that this page has everything you need to get started developing BlackBerry applications:
http://na.blackberry.com/eng/developers/resources/tutorials.jsp#tab_tab_development
Rather than copy and paste information from their guides, I’ll just point out some of the things I wish were clearer in each document.
WSS does not have a user profile service and does not allow any kind of native targeting of content to users in different groups. This is one of the more serious limitations of WSS, especially for corporate intranets, where pages might need to be customized for users in different offices. MOSS, on the other hand, allows for the creation of audiences and easy targeting of content. As is typically the case with WSS, it is possible to achieve this functionality by writing code.
One way to do this is by adding a reference in your code to “System.DirectoryServices,” which allows you to query Active Directory. With that class, you can compare the current user to an Active Directory group’s membership collection, and add logic based on whether or not the user is in the group. If you plan to edit an aspx page directly, you will also have to add a page parser path in web.config, so that the code in the page will run. Rather than editing the page directly, it is often preferable to create a control or web part for security and manageability reasons.
If editing an aspg page directly in SharePoint Designer, just add the following line to the top of the page, so that the correct assembly is referenced.
<%@ Assembly Name="System.DirectoryServices, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" %>
Then add a code block into the page that gets the current user and compares it to the group membership. The following example uses VB.Net and sees if the current user is in the “NY Staff” group. If so, then the script redirects to the page “NY.aspx.” Rather than redirecting, you could also add code to write out customized content based on the membership information.
<%
Try
'Get group membership for current user
Dim DomainUser As String = Replace(User.Identity.Name, "\", "/")
Dim ADEntry As New System.DirectoryServices.DirectoryEntry("WinNT://" & DomainUser)
Dim MembersCollection As Object 'Underlaying is a IADsMembers interface
MembersCollection = ADEntry.Invoke("Groups")
Dim group As Object 'IADsGroup interface
Dim vFound As Boolean = False
For Each group In MembersCollection
If LCase(group.Name) = "ny staff" Then
vFound = True
Exit For
End If
Next
'Do something if group is found
If vFound Then
Response.redirect("NY.aspx")
End If
Catch ex As Exception
'response.write(ex.message)
End Try%>