Wednesday, April 30, 2008

Automating the install of the SharePoint Application Templates

One of the things we do for our site administrators is load all the Microsoft SharePoint and WSS application templates. This gives them a broad range of templates to suite their needs. Installing these templates is time consuming so I created a batch file that automates this process and I just wanted to share it with my readers.

Copy the following code into a text file and rename the file extension to .bat.

REM **********************BEGIN BAT FILE**********************
ECHO ON
REM AllTemplates.exe has to be on the logged-in users desktop

%USERPROFILE%\Desktop\AllTemplates.exe /T:%TEMP% /C /Q

set SPAdminTool=%CommonProgramFiles%\Microsoft Shared\web server extensions\12\BIN\stsadm.exe

"%SPAdminTool%" -o addsolution -filename "%TEMP%\ApplicationTemplateCore.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\AbsenceVacationSchedule.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\BudgetingTrackingMultipleProjects.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\BugDatabase.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\CallCenter.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\ChangeRequest.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\ComplianceProcessSupport.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\ContactsManagement.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\DocumentLibraryReview.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\EventPlanning.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\ExpenseReimbursementApproval.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\HelpDesk.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\InventoryTracking.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\ITTeamWorkspace.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\JobRequisition.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\KnowledgeBase.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\LendingLibrary.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\PhysicalAssetTracking.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\ProjectTrackingWorkspace.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\RoomEquipmentReservations.wsp"
"%SPAdminTool%" -o addsolution -filename "%TEMP%\SalesLeadPipeline.wsp"

"%SPAdminTool%" -o deploysolution -name "ApplicationTemplateCore.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "AbsenceVacationSchedule.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "BudgetingTrackingMultipleProjects.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "BugDatabase.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "CallCenter.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "ChangeRequest.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "ComplianceProcessSupport.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "ContactsManagement.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "DocumentLibraryReview.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "EventPlanning.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "ExpenseReimbursementApproval.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "HelpDesk.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "InventoryTracking.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "ITTeamWorkspace.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "JobRequisition.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "KnowledgeBase.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "LendingLibrary.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "PhysicalAssetTracking.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "ProjectTrackingWorkspace.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "RoomEquipmentReservations.wsp" -allowgacdeployment -immediate
"%SPAdminTool%" -o deploysolution -name "SalesLeadPipeline.wsp" -allowgacdeployment -immediate

"%SPAdminTool%" -o addtemplate -filename "%TEMP%\BoardDirectors.stp" -title "BoardDirectors.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\BusinessPerformance.stp" -title "BusinessPerformance.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\CaseManagement.stp" -title "CaseManagement.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\ClassroomManagement.stp" -title "ClassroomManagement.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\ClinicalTrial.stp" -title "ClinicalTrial.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\CompetitiveAnalysis.stp" -title "CompetitiveAnalysis.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\DiscussionDatabase.stp" -title "DiscussionDatabase.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\DisputedInvoice.stp" -title "DisputedInvoice.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\EmployeeActivities.stp" -title "EmployeeActivities.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\EmployeeBenefits.stp" -title "EmployeeBenefits.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\EmployeeTraining.stp" -title "EmployeeTraining.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\EquityResearch.stp" -title "EquityResearch.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\ManufacturingProcess.stp" -title "ManufacturingProcess.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\MarketingCampaign.stp" -title "MarketingCampaign.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\NewStoreOpening.stp" -title "NewStoreOpening.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\ProductPlanning.stp" -title "ProductPlanning.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\RequestForProposal.stp" -title "RequestForProposal.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\SportsLeague.stp" -title "SportsLeague.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\TeamWorkSite.stp" -title "TeamWorkSite.stp"
"%SPAdminTool%" -o addtemplate -filename "%TEMP%\TimecardManagement.stp" -title "TimecardManagement.stp"

"%SPAdminTool%" -o execadmsvcjobs

PAUSE
REM **********************END BAT FILE**********************

Thursday, April 24, 2008

Escape Characters in SharePoint

This is more for my own information...

The format SharePoint expects is:

_x00[the sharepoint escape code from below]_

CharacterSharePoint Escape Code
underscore2d
dash27_
[space]20
<3c
>3E
#23
%25
{7B
}7D
|7C
\5C
^5E
~7E
[5B
]5D
`60
;3B
/2F
?3F
:3A
@40
=3D
&26
$24

Wednesday, April 09, 2008

Five Ways to Manage a SharePoint Site Collection with SharePoint

EndUserSharePoint.com has a very interesting article on managing SharePoint site collections within the enterprise. My employer is currently in the initial stages of creating the topology of our SharePoint portal and this is an interesting take on governance. Definitely a good read.

Check out the article here...

Monday, April 07, 2008

Creating Custom SharePoint Timer Jobs

Andrew Connell does a great job laying out in detail the steps to create a SharePoint time job. Classic .Net developers can equate this to a service we would have created to act on a business rule at a specified increment in time. Our shop implemented this sort of functionality for daily reports, email alerts and other admin alerts.

Check out his article...

Sunday, April 06, 2008

SharePoint 2007 Link List 4/6/2008

Style up your Best Bets results in SharePoint
http://clintcherry.spaces.live.com/Blog/cns!AEC0DCBC460E45B9!563.entry

Creating custom Views on Surveyshttp://www.sharepointblogs.com/ggill1970/archive/2008/04/02/creating-custom-views-on-surveys.aspx

Hidden Content Types and Site Columns in SharePoint
http://clintcherry.spaces.live.com/Blog/cns!AEC0DCBC460E45B9!566.entry

How to create a custom e-mail alert alert handler in Microsoft Office SharePoint Server
http://support.microsoft.com/kb/948321/en-us

SPSite security context and the SPUser
http://daniellarson.spaces.live.com/blog/cns!D3543C5837291E93!1774.entry

SharePoint Products and Technologies Customization Best Practices
http://msdn2.microsoft.com/en-us/library/bb861954.aspx

Thursday, April 03, 2008

Applying unique constraints to SharePoint list columns

This is a much needed solution in SharePoint. Next up, foreign keys...
Nice job Scott.
http://scothillier.spaces.live.com/blog/cns!8F5DEA8AEA9E6FBB!293.entry

Tuesday, April 01, 2008

Question: STSADM CreateWeb Does not Add to QuickLaunch

We have been in the process of creating scripts for deploying our SharePoint portal. We first scripted out the Site Collection using "stsadm -o createsiteinnewdb" so we can keep our organizations in their own content database. Nested with deach createsiteinnewdb call were multiple "stsadm -o createweb" calls for each organizations divisions to have their own subsite. Here is the kicker. Using stsadm to create subsites does not add the subsite to the quick launch under Sites.

Does anyone know how to script this out...it works using the GUI but that means we will have to create 30+ subsites using the GUI...I'd rather script it out.