
Wednesday, March 11, 2009
Creating the Structure for a SharePoint Theme in VSeWSS v1.3
So VSeWSS doesn’t provide a Visual Studio project type to create Themes. So we have to start out with a SharePoint –> Blank Project. Then we add a Root File
Then we need to create a structure something like this (if we want to be nicely multilingual aware) So creating these by hand is a bit of a pain in the arse… especially if you have to do it during a presentation (come to my presentation at MIX09! ‘State of the Art in Web Site Design on Microsoft SharePoint’). So I wrote a little Macro that creates these folders for you… thought it might be useful to some people. Sub TemporaryMacro()
Dim themeName As String = InputBox("Enter the template name")
Dim rootItem As ProjectItem = DTE.Solution.Projects.Item(1).ProjectItems.Item(2)
Dim templateItem As ProjectItem = rootItem.ProjectItems.AddFolder("TEMPLATE")
templateItem.ProjectItems.AddFolder("THEMES").ProjectItems.AddFolder(themeName)
templateItem.ProjectItems.AddFolder("LAYOUTS").ProjectItems.AddFolder("1033") _
.ProjectItems.AddFolder("IMAGES").ProjectItems.AddFolder(themeName)
End Sub
Hope it’s helpful for people.
.NET | SharePoint|Wednesday, March 11, 2009 12:12:51 AM UTC||
|