Archive | SharePoint RSS for this section

Here’s the deal, sometimes when you write SharePoint code on your dev machine, it deploys just fine. When you package it and deploy it on another server, it doesn’t always work so hot. Furthermore, you might sometimes experience this exception on dev box:

Error occurred in deployment step ‘Add Solution’: Failed to load receiver assembly “…”.
System.IO.FileNotFoundException: Could not load file or assembly ‘…’ or one of its dependencies. The system cannot find the file specified.
at …
at …
at Microsoft.SharePoint.Administration.SPFeatureDefinition.get_ReceiverObject()

So what’s going on here? Well, it’s quite simple, and yet, it is almost haunting. The fact is, Visual Studio doesn’t always pick up your changes when it builds your solution. It seems to think that that if you haven’t changed the code, when you build your solution it shouldn’t compile a new DLL. That annoys me because sometimes I actually need it to rebuild that DLL for me. If I tell VS to build, I’m thinking it’s going to recompile all of the DLLs for me (note to self: build != recompile). As my friend James S. says, “There’s your problem.” In other words, “stop thinking; start doing.”

So, I’ve been paranoid about packaging my code. First, I intend to clean up my dev box and run a test deployment on it as an ITPro would on his/her Test environment. Second, I deploy to a Test farm. So the goal in VS is to get a fully compiled .sln file. To confidently get that, I perform a manual clean, build, package, and then test it.

Here are my steps:
1. Right-click the project and Retract
2. Verify the feature is gone from the filesystem, the DLLs are no longer in the GAC, etc.
3. In Visual Studio’s Solution Explorer window, click Show all files
4. Control-click bin, obj, pkj, pkjobj
5. Delete and confirm delete
6. Right-click the project and Build
7. Right-click the project and Package

Now I know for sure that everything in the package is using the latest code, settings, etc.
And yes, I realize there is a Clean function. I don’t trust it. Do you?

OneNote 2010 Requires the Windows Desktop Experience

I’m trying to copy some code from Reflector into OneNote 2010. Unfortunately, OneNote requires the Windows Desktop Experience. What a bummer. Now my VMs need to have the DE feature installed.

Use PowerShell to quickly show your SharePoint Features

I wanted to know what features were installed on my farm. Not just farm-scoped features, but all feature scopes. So I wrote some quick powershell to tackle the job.

Here is a screenshot of the code for easier reading.

Alt text for the script

Script to display all SharePoint features

Here is the code so that you can copy/paste.

clear-host;
Add-PSSnapin Microsoft.SharePoint.Powershell
write-host "Farm scoped features"

# This will display all Farm scoped features
#Get-SPFeature -Farm 

# This will display a specific Farm scoped feature if it exists
Get-SPFeature -Farm | where { $_.Id -eq "319d8f70-eb3a-4b44-9c79-2087a87799d6" }

write-host 

foreach ($webapp in get-spwebapplication) {

  write-host "Web Application " $webapp.url  

  # All WebApplication scoped features
  #Get-SPFeature -WebApplication $webapp.url 

  # specific WebApplication scoped feature if it exists
  Get-SPFeature -WebApplication $webapp.url | where { $_.Id -eq "0ea1c3b6-6ac0-44aa-9f3f-05e8dbe6d70b" }
  write-host 

  foreach ($site in $webapp.sites) {

    write-host "Site Collection " $site.url 

    # All SiteCollection scoped features
    #Get-SPFeature -Site $site.url 

    #specific SiteCollection scoped feature if it exists
    Get-SPFeature -Site $site.url | where { $_.Id -eq "7094bd89-2cfe-490a-8c7e-fbace37b4a34" }

    write-host 

    foreach ($web in $site.AllWebs) {

      write-host "Web " $web.url 

      # All Web scoped features
      #Get-SPFeature -Web $web 

      # Specific web scoped feature if it exists
      Get-SPFeature -Web $web | where { $_.Id -eq "00bfea71-1e1d-4562-b56a-f05371bb0115" }

      write-host
    }
  }
}
write-host "Done"

Recap of SharePoint Saturday Houston

SharePoint Saturday Houston was May 1. I’ve been pulling my thoughts together for a couple of weeks now.  I want to evaluate each aspect of the event in highlight. I am not going to discuss each bullet point on a blog. If you have questions or varying opinions, I’d sure love to hear them in the comments.

Let’s begin with facilities. The Norris Center is an awesome facility for a conference this size.

  • It has 5 rooms for tracks, each holding 50 to 100 people
  • It has an enormous lunch room
  • It is well run
  • They had great food and plenty of it: snacks, excellent lunch, and refreshments in every room all day

The quality of speakers was remarkable. 

  • I’m not going to name any names. 🙂
  • We had a good balance of local representatives and people from around the region, and a few from each coast
  • We had great topics with people who are considered some of the experts in their fields
  • We had general, case study, architecture, administration, and developer’s covered

The schedule.

  • Here’s where I fess up. I was part of the committee who decided to have tracks go until 6pm. That was a mistake.
  • We would have been better off with one less time slot and a little longer presentation sessions.
  • Nonetheless, the session content was great, we had plenty of time to sit down and eat, and we still had time to give away the swag!

Supporters (Vendors)

  • The vendors were awesome.  They contributed the funds to make this happen. And from what I heard, they felt it was a good investment.
  • They did a great job of engaging with the guests
  • They did not make you feel obligated to talk to them (SPC, PDC, etc, the vendors were a bit more grabby)
  • I feel like they respected people and valued their time.

Volunteers

  • Volutneers were great.
  • I think we needed just a couple more “runners” if you will.
  • They were helpful and very accomodating.

Overall, this was a great event. I am glad that I was able to be a part of it!

See you at Houston TechFest on October 9, 2010!

SPS DC

Tomorrow I am flying out to Washington, D.C., in order to speak at SharePoint Saturday DC, aka, SPSDC. It should be a fun time. I look forward to presenting on MMS and all the wonderful questions and insights that attendees bring.

If you are going to SPSDC, but sure to say hi.

STSADM to PowerShell mapping

http://technet.microsoft.com/en-us/library/ff621081(office.14).aspx

For those joining me in learning powershell for SharePoint, here is a handy reference on technet mapping the ststadm commands to PowerShell commands.

SQL Server R2 RTM

SQL Server 2008 R2 officially RTM’d.

I’ve been working with the SQL CTP and SharePoint Beta, and the BI story is pretty incredible.  Here’s a quote that’s pretty accurrate (it’s not as easy as they make it sound, but the BI capabilities are still pretty impressive).

With the release of SQL Server 2008 R2, Microsoft is introducing powerful new managed self-service BI capabilities, bridging the gap between IT professionals and end users by leveraging familiar tools such as Microsoft Excel 2010 and Microsoft SharePoint Server 2010. With the new BI technology named PowerPivot, end users can bring data from virtually anywhere and manipulate large datasets with ease while still enabling IT to monitor and manage user-generated BI solutions.

As soon as the code his MSDN, it’ll be time to rebuild the SharePoint 2010 SQL server.

TechNet blog found here:  http://bit.ly/SQL2008R2RTM  
Press Release found here: http://www.microsoft.com/Presspass/press/2010/apr10/SQL08RTMPR.mspx