Author Archive for Russell Wright



26
Jan
11

Timer Job Failure on user profile service in SharePoint 2010

The incremental User Profile Service timer job was failing.

image

After looking around, I also noticed the User Profile Service would not start correctly.

image

The Forefront Identity Manager Service and Forefront Identity Manager Synchronization Service were both disabled for some reason.  I set them to Automatic.  They already had the SPFarm credentials assigned to them.

image

Now the User Profile Service starts correctly and the incremental job runs successfully.

References

Provisioning the User Profile Service Application

Forefront Identity Manager errors when starting the SharePoint 2010 User Profile Synchronization Service Application

Plan Security Hardening

Provisioning User Profile Synchronization

26
Jan
11

What the heck is going on with SharePoint 2010 slide Libraries?

For all the great features added to SharePoint 2010, it is still mind boggling to see what issues remain with the user experience.  Take this recent experience with SharePoint 2010 slide libraries.  Terry turned me on to this in his instance so I began a validation in my instance.  My instance is currently patched with the October 2010 CUs.

I published a PowerPoint presentation to a slide library in SP2010 that had “require check in/out” enabled.  All slides were published in a checked out status.  I needed to check them in.  No problem, select multiple slides with the new “multiple selection” feature and check in. 

Nope, can’t do it.  Security issue?  I’m a logged in as a site collection administrator and I’m in the Owners group that has access to the slide library.  Shouldn’t have a problem there.

image

Okay, let’s see what happens if I don’t select multiple slides. 

Nope, tool ribbon is still disabled.  Even tried enabling “protected mode” in IE for trusted sites (in which this site resides).

image

Do I have access to check-in from the drop-down?  Yes.

Does it work?  Yes.

image

Now the special triple click trick.  Click the disappearing drop-down button.  The context sensitive drop-down list appears.  Click it again and the button disappears…but the drop-down list remains.  Click again and the drop-down list disappears.  Ahhh…the wonders of Ajax.  But I digress.

image

Let’s take a look at this problem from an SPD perspective.  We can see the files that are checked out.

image

Let’s select three files and check them in.

image

After performing a check-in, we still see the “checked-out” checkmarks.  Even the context-sensitive menu is confused about whether these slides are checked in or checked out.

image

Perhaps it’s that nagging problem with SPD where it doesn’t refresh correctly.  Press F5.  No change.

After closing and reopening the site in SPD.  No change.

From the browser UI I validated that they are still checked out.  Another non-functional feature?

image

It looks like SPD continues to be confused as to the status of the slide, even after closing SPD and starting a new instance.

image

SPD shows the same slide as checked out.  No amount of F5-ing changes this.

image

Hey, let’s try to use this feature to allow us to “manage files which have no checked in version.”

image

But wait!  There are no checkboxes with which to select the items? 

image

Perhaps I can use the “select all” checkbox.

Nope.  The "select all” checkbox is non-functional.  What’s up with this?

image

Oh, and this appears to work just fine on a document library in the same site.

image

I’m certainly open to others’ experiences with Slide Libraries in 2010.  Perhaps the Dec 2010 CUs will help?

As another test I went into SPD 2007 and tried the same thing.  No check-in will occur from SPD 2007.  So, I guess they didn’t break anything.

image

References

SharePoint Slide Library Adding Functionality

19
Jan
11

“Your search cannot be completed because this site is not assigned to an indexer” on SharePoint 2010 Foundation

SharePoint 2010 Foundation problems encountered when doing a quick spin-up of a test instance.

  • Search service wouldn’t start
  • Performing a search returned the error “Your search cannot be completed because this site is not assigned to an indexer”

To allow the search service to start the credentials assigned to the service were changed from Local Service to Local System.

To fix the “not assigned to indexer” error use Central Administration.

Navigate to “Manage content databases.”

image

Make sure you have the correct web application selected and click on the content database.

image

Scroll down and find the Search Server section and select the search server from the drop-down.

image

13
Jan
11

Adding multiple graphs (stacked bar and line) to an excel chart

I don’t normally blog on Excel, but since I was working with Excel Services and asked to create some KPIs to display using Excel Services, I thought it had some relationship to SharePoint.  So, let me be the first to say I’m not an Excel expert, but I can usually get it to do what I want it to do…after spending the time.

I really like the business part of SharePoint.  I like “SharePoint-tizing” business processes and figuring out the business side of things.  Let’s face it…SharePoint is a tool just like Excel, Word, PowerPoint, SAP, PeopleSoft, Oracle…and it’s really about the skill you apply to using the tools to provide the maximum business benefit.  While “I love technology” (one of my favorite songs from Napoleon Dynamite), I much prefer to figure out how to apply it in real business scenarios.

Publishing KPIs is a great way to get people on the same track and thinking about the same important goals in your business.  With Excel Services you can easily do this and, if you have a good back-end data source, you can connect your workbook to the live data.  In order to get started and prove out your KPIs, you may want to simply publish some items out of an Excel workbook that someone is manually updating on a regular basis.  That’s where we’re coming from in this example.

I have some data (employee headcount) and I want to create a combination graph that shows the prior year’s (2009) ending headcount by group and continue with showing the monthly headcount for each of the groups for the new year (2010).  This is what I was shooting for (and finally obtained).

image

The stacked column is showing the ending headcount from 2009 and the lines are showing the monthly headcount for 2010.  Here’s my original data.

image

Creating the original line graphs is easy.  Insert a chart and select the line chart and select the entire table of data and Excel will perform its magic.

image

image

That was easy.  Total time, 60 seconds.  Now we need to use the trick of adding another series to the chart and formatting it as a different graph (chart) type.  But first, we need to add a column to hold our data…or create another small table with our year-end stats.

image

  • Select the data and press Ctrl-C to copy it to the clipboard.
  • Click on the graph to select it (very important, so the paste option has the correct context).
  • Use the “Paste Special…” clipboard feature to paste the new series into the existing graph.

image

  • Use the default settings:  New series, Columns and click OK.

image

Notice that the series is added as another line.

image

Now you can change this to a column graph.

  • Right-click on the series and select “Change Series Chart Type…”

image

  • Select the stacked column chart type and click OK.

image

Notice you end up with a chart that doesn’t look like what we want it to look like.  There is no space in the X axis for the “YE 2009” label and the data from the year end totals is not stacked.  WRONG ANSWER!  Start over.

image

  • Right-click on the series you added and click Delete.

image

What we need to do is add each group’s year end total as a separate series using the same technique as we did previously.

  • Select the data for the first group and copy it to the clipboard.
  • Select the chart by clicking on it.
  • Select “Paste Special…”

image

  • Click OK using the defaults from the Paste Special action.

image

You’ll notice very little change in the chart.  What you should notice, however, is the addition of another “Group A” label in the legend.  The reason you don’t see anything on the graph is that the graph is simply a single point and it is being covered up by the other lines.

image

To select the new “point series” you can click around on the chart where you know it should be located, or you can use the Current Selection tools that are located on the far left of the Chart Tools | Layout and Chart Tools | Format tool ribbons. 

image

You should be able to identify the new “Group A” series and select it from the drop-down.

image

When you select it from the drop-down, the series will be selected on the chart.

image

Now you can change the chart type by using “Change Chart Type” in the Chart Tools | Design tool ribbon.

  • Click on “Change Chart Type” or carefully right-click on the selected series (takes a steady hand).

image

  • Select the stacked column chart and click OK.

image

You should see the first part of your stacked column graph appear.

image

Now let’s add the next series.  It’s basically repeating the above process.

  • Select the data and copy to the clipboard.
  • Select the chart.
  • Select “Paste Special.”
  • Click OK to add the series.
  • Select the “point series” using the drop-down in the Current Selection area of the Chart Tools | Layout ribbon.
  • Change the chart type by using “Change Chart Type” in the Chart Tools | Design tool ribbon.

image

You should see another bar get “stacked.”

image

Repeat the process for the final series.  Now that the stacked column graph as been added to the chart, it’s time to do a little clean up.

image

First, let’s make a space for the “YE 2009” label on the X axis.  We’ll do this by adding a new column to our original data and leaving the data blank.

image

Next, we’ll expand our selection for the original data.

  • Right-click on the graph and click Select Data…

image

  • Click the Edit button to edit the horizontal axis labels.

image

Notice that the range that is selected only includes the original 12 months. 

image

  • Re-select the range to include “YE 2009” and click OK.

Notice that the “YE 2009” label is added to the chart.

image

  • Select one of the original series and click the Edit button. 

image

  • Select the series values to include the blank “YE 2009” column and click OK.
  • Repeat this process for each series (Group A, Group B, Group C and Total).
  • Click OK to close the dialog.

image

Your graph should resemble this.

image

You can delete the redundant legend entries, if you like, by clicking on the legend entry until a single one is selected and pressing the delete key.

image

Now, if you want, you can select each of the series and format them manually to change their colors to be consistent between the line and column graphs, if they are not already.

image

The final product.

image

That was rather long-winded, but I hope it has helped you as much as it has helped me to document what I did, because it might be months or years before I do it again!

30
Dec
10

Can’t update record in datasheet view

Here’s a simple one, but it underscores how important good error messages are.

You are in SharePoint 2010 on a task list and you are attempting to update the task status and other columns using the datasheet view.  You get an error:

“An unexpected error has occurred.  Changes to your data cannot be saved.  For this error, you can retry or discard your changes.”

You are presented with the following dialog.

image

Not very helpful, huh?

No matter how many times you retry your changes, you get the same general error. 

So you try to update the item using a standard SharePoint form and you receive an error with a little more meat.

“This item cannot be updated because it is locked as read-only.”

image 

Now you are suddenly reminded that in-place records management is enabled!

image

You check the Compliance Details for the item and find that you declared it as a record before Christmas and that has put a read-only lock on the item.

image

You also find your memory is mush from the holidays.  There is no solution for that.

19
Dec
10

Removing the view selector from a Sharepoint 2010 infopath form

If you have created custom InfoPath forms for a list in SharePoint 2010 and you have custom views for each of the New, Edit and View forms, you might find the InfoPath view selector showing up when you don’t want it to.  This could allow users to change to the Edit view on your New item form, for example.

image

To fix this, you can select the View Properties from the Page Design menu in InfoPath and uncheck the “Show on the View menu when filling out the form” option.

image

 

image

If all of your views have this unchecked, then the view selector will not appear on the SharePoint InfoPath form.

03
Dec
10

Conditional Formatting and date comparisons with SharePoint Designer 2010

So here’s a fun one that we at SharePoint Rx were struggling with the other day. 

We were creating a dashboard using the DVWP in SharePoint Designer 2010 and had to perform some date comparisons to control the display of indicators.  If you’ve used SPD in the past, you know that the goal is to NOT write code, but to use the “coding by clicking” capabilities of SPD and allow it to write the code (in this case XSL) to control your conditional formatting.  Every time I use SPD for something like this, I always seem to run into a new problem, even though I know it should be a simple task. 

“Am I the only one with this issue?” he asks.

Here’s the end goal…to display a status indicator for tasks to indicate whether they were completed on time, completed late, not complete and not late, and not complete and late.  You can see the four icons I chose to indicate these statuses. 

image

My “conditions” are as follows:

clip_image001 Status equals “completed” and Due Date >= Completed Date

clip_image002 Status equals “completed” and Due Date < Completed Date

clip_image003 Status not equals “completed” and Due Date >= [Current Date]

clip_image004 Status not equals “completed” and Due Date < [Current Date]

One of the issues you immediately experience is the comparison of date values.  Using SPD, I did an “un-advanced” comparison in my condition statements and never got the correct results.  SPD wrote some XSL like this (I broke it up so it’s a little easier to read):

<xsl:if test=”normalize-space($thisNode/@Status) = ‘Completed’

and

ddwrt:DateTimeTick(ddwrt:GenDisplayName(string($thisNode/@DueDate))) &gt;=
normalize-space(@Completed_x0020_Date)” ddwrt:cf_explicit=”1″>

<img src=”_layouts/images/kpinormal-0.gif” width=”16″ height=”16″ />

</xsl:if>

So we have a “Due Date” that has been operated on by ddwrt:DateTimeTick (see if you can find any documentation on this function) and is returning the number of days from January 1, 1900 comparing to the “Completed Date” in the form “MM/DD/YYYY.”  That doesn’t work!

Sidebar rant…Come on, Microsoft!  The only documentation on the ddwrt namespace is from a non-MS person (Serge van den Oever ) and is from 2005…for SharePoint 2003?

So, let’s look at the “Advanced” condition criteria that does work.

image

We used the completely undocumented ddwrt:DateTimeTick function and applied it equally to both dates.

image

When performing the comparison with [Current Date], here’s what we did.

image

We were successful with using the $Today variable, but I’ve seen others who have also used ddwrt:Today.

image

Here are the criteria for all four conditions.

@Status = ‘Completed’ and ddwrt:DateTimeTick(ddwrt:GenDisplayName(string(@DueDate))) >= ddwrt:DateTimeTick(ddwrt:GenDisplayName(string(@Completed_x0020_Date)))

@Status = ‘Completed’ and ddwrt:DateTimeTick(ddwrt:GenDisplayName(string(@DueDate))) < ddwrt:DateTimeTick(ddwrt:GenDisplayName(string(@Completed_x0020_Date)))

$thisNode/@Status != ‘Completed’ and ddwrt:DateTimeTick(ddwrt:GenDisplayName(string($thisNode/@DueDate))) >= ddwrt:DateTimeTick(ddwrt:GenDisplayName(string($Today)))

$thisNode/@Status != ‘Completed’ and ddwrt:DateTimeTick(ddwrt:GenDisplayName(string($thisNode/@DueDate))) < ddwrt:DateTimeTick(ddwrt:GenDisplayName(string($Today)))

Now, I’d like to believe that features in SPD 2010 that were in SPD 2007 were all functioning correctly, but I seem to have lots of problems using the “All formatting visible” functionality.  I found that each time I changed this I must

  • Save the page
  • Press F5 to refresh (sometimes more than once)

Not sure what that’s about or if it’s just one of my settings, but it sure is annoying.

image

Of course, the idea is that you want to make all your conditionally formatted elements visible so you can easily work on them.

image

FYI, if you want to determine which condition applies to which element, you can select the condition and you should notice a highlighting of the element to which the condition corresponds. 

image

Keywords:

Conditional formatting

SharePoint Designer 2010

Date comparison

Data view web part

ddwrt namespace

01
Dec
10

Updating the Application Pool Account on a SharePoint 2010 Site

I was working on changing the security on a 2010 site to use domain accounts instead of local and built-in accounts.  The problem I was having was that a non-administrative user couldn’t log into the SharePoint site, even though the user was a site collection administrator.

I created an app pool account to use (spDemoAppPool) and used SCA (SharePoint Central Administration) to register the account and assign the account to the application pool to replace the Network Service account.

image

image

After making this change, I ran the configuration wizard to have it fix the security on the app pool account.  However, I found that it didn’t fix all the security.  When looking at this Technet article, I found that the SQL security in the last two bullets was not correctly assigned.

http://technet.microsoft.com/en-us/library/cc678863.aspx#Section3

Other application pool accounts

The other application pool account must be a domain user account. This account must not be a member of the administrators group on any computer in the server farm.

The following machine-level permission is configured automatically: This account is a member of WSS_WPG.

The following SQL Server and database permissions are configured automatically:

  • This account is assigned to the db_owner role for the content databases.
  • This account is assigned to the db_owner role for search databases associated with the Web application.
  • This account must have read and write access to the associated service application database.
  • This account is assigned to the WSS_CONTENT_APPLICATION_POOLS role associated with the farm configuration database.
  • This account is assigned to the WSS_CONTENT_APPLICATION_POOLS role associated with the SharePoint_Admin content database.

If you use SQL Server Management Studio, you can find the SharePoint Config and Admin_content databases and look at the properties on the WSS_Content_Application_Pools database role.

image

image

From here, I selected the checkbox next to my spDemoAppPool account and clicked OK.

image

That appeared to fix my problem.

Now on to this problem…

http://www.thereforesystems.com/sharepoint-installation-failed-to-create-sample-data/

18
Nov
10

Setting up the IIS SMTP Server for Sending Email from SharePoint 2010 on Server 2008 R2

Insure that the IIS role is installed on your server.  Then, make sure that the SMTP Server feature is enabled.

image

The SMTP service should be started.

image

Open the IIS 6.0 Manager so you can manage the SMTP server settings.

image

Right-click to open the properties dialog.

Click the Authentication button.  Ensure that anonymous access is selected (SharePoint requires this).

image

Use the Connection button to Add computer(s) that can connect to this SMTP server.  Since it is anonymous, you want to be very selective.

image

Use the Relay button to add computers that can relay through the virtual server.  Again, necessary for security.

image

Select the Delivery tab.  We’re assuming you have to authenticate to your email provider to forward and send email through them.

image

Click the Outbound Security button.  This shows using basic authentication with TLS encryption (pretty standard from what I’ve seen).

image

Click the Outbound Connections button.  In many cases you’ll have to change the TCP port from the default of 25.  My provider uses 587.

image

Clicked the Advanced button.  In the Advanced Delivery dialog, enter the SMTP server in the Smart host field and a Masquerade domain.  The Masquerade domain name replaces the local domain name listing in Mail From lines in the SMTP protocol (your SMTP server may be in a domain such as mail.yourdomain.com).

image 

Set the Outgoing E-Mail Settings in SharePoint Central Administration.  Notice there are no security settings.

image

03
Nov
10

Limiting the Search Scope using contentclass in a Property Query Scope Rule

If you find yourself needing to limit the scope of a search to only the items in a list (i.e. you don’t want to return any of the view forms and other aspx pages in the search results) you can use the contentclass as part of the search scope definition.  This is a great way to limit the search results to only the content in a list or library.  Use the STS_ListItem_DocumentLibrary string to implement this rule.

There’s a good article on Jose Barreto’s blog that has a list of the contentclass filter strings.  Niels Loup also has good info on this topic.

Basically you are creating a scope rule using a property query and specifying the property restriction of "contentclass" and making it "required."  This scope rule can be combined with others to define what the scope returns.

image

Keywords:

contentclass

Property Query

Scope Rule

SharePoint MOSS 2007 Search

STS_ListItem_DocumentLibrary




Asif Rehmani’s SharePoint Videos

SharePoint-Videos

Click to access a wealth of SharePoint videos

SharePoint Rx

SharePoint Rx Home

Categories

Posts by Date

May 2012
M T W T F S S
« Mar    
 123456
78910111213
14151617181920
21222324252627
28293031  
Support Wikipedia

Follow

Get every new post delivered to your Inbox.