Navigation

Search

Categories

On this page

Sharepoint Developer Links
How do you move a WSS 3.0 database to a different SQL Server?
AJAX Tab control: Tabs display incorrectly in IE7
Using the AJAX Control Toolkit in Sharepoint
Sharepoint 2007 Deployment Solutions
Code-blocks are not allowed in this file: Using Server-Side Code with SharePoint

Archive

Blogroll

Disclaimer
The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

RSS 2.0 | Atom 1.0 | CDF

Send mail to the author(s) E-mail

Total Posts: 103
This Year: 41
This Month: 6
This Week: 2
Comments: 0

Sign In

 Thursday, January 10, 2008
Thursday, January 10, 2008 6:51:03 PM (Eastern Standard Time, UTC-05:00) ( )


Here some links I've come across that I've found helpful

Building a Hello World Web Part for Windows SharePoint Services 3.0
http://aspalliance.com/1480_Building_a_Hello_World_Web_Part_for_Windows_SharePoint_Services_30.all
Based on this Ted Pattison video: http://go.microsoft.com/?linkid=6471616

Creating and Using Event Handlers in Windows SharePoint Services 3.0
Video: Ted Pattison
http://go.microsoft.com/?linkid=6471621

Creating and Testing Features with Windows SharePoint Services 3.0
Video: Ted Pattison
http://go.microsoft.com/?linkid=6471617

Creating a Custom Page Layout with SharePoint Server 2007
Video: Ted Pattison
http://go.microsoft.com/?linkid=6471618

Creating and Using Site Columns in Windows SharePoint Services 3.0
Video: Ted Pattison
http://go.microsoft.com/?linkid=6471619

Creating and Using Content Types in Windows SharePoint Services 3.0
Video: Ted Pattison
http://go.microsoft.com/?linkid=6471620

Creating and Using Event Handlers in Windows SharePoint Services 3.0
Video: Ted Pattison
http://go.microsoft.com/?linkid=6471621

MSDN Webcast: Developing SharePoint Workflows Using Visual Studio 2005 (Level 200)
http://go.microsoft.com/?linkid=6471622

SharePoint Server 2007 SDK: Software Development Kit
http://www.microsoft.com/downloads/details.aspx?FamilyId=6D94E307-67D9-41AC-B2D6-0074D6286FA9&displaylang=en

Windows SharePoint Services 3.0 Tools: Visual Studio 2005 Extensions
http://www.microsoft.com/downloads/details.aspx?familyid=19F21E5E-B715-4F0C-B959-8C6DCBDC1057&displaylang=e

 Saturday, November 24, 2007
Saturday, November 24, 2007 12:51:00 PM (Eastern Standard Time, UTC-05:00) ( )

 

I know this issue is going to come up soon for me so I've been researching possible solutions and came across this one.

http://wss.asaris.de/sites/walsh/Lists/WSSv3%20FAQ/DispForm.aspx?ID=1034

How do you move a WSS 3.0 database to a different SQL Server?

You cannot move the configuration database. 

1.  Detached the content database using SQL Manager

2.  Copied the database and log files to the new server

3.  Attached the content database to the new server

4.  Run the SharePoint Products and Technologies Configuration Wizard to remove it from the farm

5.  Run SharePoint Products and Technologies Configuration Wizard to recreate the farm and add the new database server. This will also create a
new configuration database.

6.  Once that is done, go to SharePoint Central Administration website and click on Application Management

7.  Select Create or extend web application to setup your new web application

8.  Select Content Database and add the new content database

9.  Restart IIS

 Tuesday, October 23, 2007
Tuesday, October 23, 2007 8:09:26 AM (Eastern Standard Time, UTC-05:00) (  |  )

I was experimenting with the AJAX Tab control extender which is part of ASP.NET AJAX Control Toolkit in Sharepoint.  The bottom part of the tabs was being cut off for no apparent reason.  When I would run the page locally, it would render fine but within Sharepoint, the text on the tabs was being cut off on the bottom. After several frustrating hours, I found out how to fix the CSS that was causing the problem.

After looking at the Tabs.css file, it appears that the right hand graphic on the tab control is set to a height of 21px. The tab itself with the text has a height of 13px. This can be remedied by modifying the xp theme to look like this:

.ajax__tab_xp .ajax__tab_tab {height:21px;padding:4px;margin:0;background:url(<%=WebResource("AjaxControlToolkit.Tabs.tab.gif")%>) repeat-x;}

The Tabs.css file can be found in the AJAX Control Toolkit (with source code).  I changed the CSS used by my particular theme which in my case was /_themes/Wheat/Whea101165001.css


.ajax__tabs .ajax__tab_header {font-family:verdana,tahoma,helvetica;font-size:11px;background-color:#EEE8AA;background:url("/it/images/tabs/tab-line.gif");background-repeat:repeat-x;background-position:bottom;}
.ajax__tabs .ajax__tab_outer {background:url("/it/images/tabs/tab-right.gif");background-repeat:no-repeat;background-position:right;height:21px;}
.ajax__tabs .ajax__tab_inner {padding-left:3px;background:url("/it/images/tabs/tab-left.gif");background-repeat:no-repeat;}

/* remove this line
.ajax__tabs .ajax__tab_tab {height:13px;padding:4px;margin:0;background-color:#EEE8AA;background:url("/it/images/tabs/tab.gif");background-repeat:repeat-x;}
*/

/* Add this one */
.ajax__tabs .ajax__tab_tab {height:21px;padding:4px;margin:0;background:url("/it/images/tabs/tab.gif") repeat-x;}

.ajax__tabs .ajax__tab_body {font-family:verdana,tahoma,helvetica;font-size:10pt;border:1px solid #999999;border-top:0;padding:8px;background-color:#EEE8AA;}
.ajax__tabs .ajax__tab_hover .ajax__tab_outer {background-color:#EEE8AA;background:url("/it/images/tabs/tab-hover-right.gif");background-repeat:no-repeat;background-position:right;}
.ajax__tabs .ajax__tab_hover .ajax__tab_inner {background-color:#EEE8AA;background:url("/it/images/tabs/tab-hover-left.gif");background-repeat:no-repeat;}
.ajax__tabs .ajax__tab_hover .ajax__tab_tab {background-color:#EEE8AA;background:url("/it/images/tabs/tab-hover.gif");background-repeat:repeat-x;}
.ajax__tabs .ajax__tab_active .ajax__tab_outer {background-color:#EEE8AA;background:url("/it/images/tabs/tab-active-right.gif");background-repeat:no-repeat;background-position:right;}
.ajax__tabs .ajax__tab_active .ajax__tab_inner {background-color:#EEE8AA;background:url("/it/images/tabs/tab-active-left.gif");background-repeat:no-repeat;}
.ajax__tabs .ajax__tab_active .ajax__tab_tab {background-color:#EEE8AA;background:url("/it/images/tabs/tab-active.gif");background-repeat:repeat-x;}

Also, by default, the CssClass used by the Tabcontrol is .ajax__tabs_xp.  I changed mine to use .ajax__tabs so it would use the changed Css /_themes/Wheat/Whea101165001.css rather than the CSS used by the Tabcontrol.

Other resources that helped with this issue:

 

 Saturday, October 20, 2007
Saturday, October 20, 2007 9:39:07 PM (Eastern Standard Time, UTC-05:00) (  |  )

I recently tried adding a page to WSS 3.0 which utilized one of the ASP.NET AJAX components and received the error "Error - this control is not registered as a safe control." After some digging, I found out that you have take a few steps to get these AJAX control extenders to work in Sharepoint.

  • AjaxControlToolkit.dll - Put this in your /Bin directory
  • Add an assembly reference in the web.config (note: for the future versions of the Control Tookit, the version number can change.  Right-click on the dll and go to properties to find the dll verison):

   <assemblies>
   ...
   <add assembly="AjaxControlToolkit, Version=1.0.10920.32880, Culture=neutral, PublicKeyToken=28f01b0e84b6d53e"/>
   ....
   </assemblies>

  • Add the tagprefix for the Control Toolkit in the web.config:

    <controls>
    ...
    <add namespace="AjaxControlToolkit" assembly="AjaxControlToolkit" tagPrefix="ajaxToolkit"/>
    ....
    </controls>

  • Register the assembly as a safe control:  

<SafeControls>

<SafeControl Assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" Namespace="System.Web.UI" TypeName="*" Safe="True" />
<SafeControl Assembly="AjaxControlToolkit, Version=1.0.10920.32880, Culture=neutral, PublicKeyToken=28f01b0e84b6d53e" Namespace="AjaxControlToolkit" TypeName="*" Safe="True" />

</SafeControls>

That's it.  You can now start using all of those control AJAX extenders in Sharepoint

 

 Tuesday, October 16, 2007
Tuesday, October 16, 2007 2:08:52 PM (Eastern Standard Time, UTC-05:00) ( )

I've found it surprising how tricky it is to run ordinary .aspx pages and applications in Sharepoint.  Chris Johnson from Microsoft offers some interesting alternatives on how to do this:

http://blogs.msdn.com/cjohnson/archive/2006/09/05/740498.aspx

 

One of the cooler tools I've come across for this is SmartPart which is a generic Web part allows you to host any ASP.NET user control within your SharePoint sites. It allows for a designer-driven approach to developing Web parts instead of very code-intensive approach that is available out-of-the box with SharePoint.  You can download SmartPart here. Jans offers a video and a user's guide to get you started.

 Thursday, October 04, 2007
Thursday, October 04, 2007 12:32:55 PM (Eastern Standard Time, UTC-05:00) ( )

I've started using Sharepoint at work and although I've been coding in ASP.NET a couple of years, I'm finding the learning curve a little steep. 

If you use the Microsoft Office SharePoint Designer to add a new page to your site, you will see that it looks just like any other ASP.NET page.  However, if you try an add an inline code block using the standard

<script></script>

tags, you'll receive an error similar to this one:  "An error occurred during the processing of /Pages/test.aspx. Code blocks are not allowed in this file."

Hmm… yeah, code blocks are allowed in ASP.NET pages. SharePoint disables the ability to create server-side script by default, you have to turn it on. You do that in the web.config file, in the configuration/SharePoint/PageParserPaths configuration section:

<PageParserPaths>

  <PageParserPath VirtualPath="/pages/test.aspx" CompilationMode="Always" AllowServerSideScript="true" />

</PageParserPaths>

By the way, there are multiple web.config files and the one you should edit is C:\Inetpub\wwwroot\wss\VirtualDirectories\80\web.config