SharePoint
There are 14 entries for the tag
SharePoint
I few months ago I posted on RenderPatterns and how they are used when creating custom fields for SharePoint. In that post the point I was trying to make was that when viewing data in a list nothing else matters except the render pattern. None of your highfalutin C# SPField derived classes can save you from the madness that is the render pattern. Never mind what MSDN says about using an .ascx control - there is no other way. So with that said, given that we’re stuck with the render pattern, it would be good to know a bit...
When you upload images to a SharePoint picture library three images are actually stored. Firstly there's the actual image that you uploaded then there are two others with specific sizes. There’s a thumbnail image that’s scaled to a particular width and is used in the default ‘All Pictures’ view then there’s a web image that’s resized to a specific width and height. The thumbnails are saved to a hidden folder in the picture library named _t and the web images are saves to a hidden folder named _w. Let’s say you have a few web parts that make use...
Ever tried to add a custom field control to a Custom List Form in SharePoint Designer? You’d think it’d be simple, just drag the field from the toolbox and stick it on the form. Nah! We haven’t heard much from Ernő Rubik in recent years. I’m convinced he’s at Microsoft working on the SharePoint team (and doing a bit of work in the WF team when he’s got a chance) You’ll come across a few problems when trying to add your custom field control (or any other type of custom control) to a custom list form. As you may...
A few weeks ago I promised to post a few articles about extending CAML to deal with some of the elements that you’d normally have to write code in order to package. To be honest I’ve been putting it off in the hope that SharePoint 2010 and VisualStudio 2010 would make all these problems go away but it seems that that isn’t going to happen, at least not completely. So no more excuses, I may as well get on with it! I wanted to cover Lookup fields in this post. Somebody recently asked about this on the forums and...
I like to follow what’s going on on the SharePoint forums and one of the things I’ve noticed is that practically every day somebody starts a thread about RenderPatterns. Either they’ve created a custom field and they want to know how to use RenderPatterns or they’ve read through the documentation, have created a RenderPattern and it doesn’t do what they expect. I thought I’d spend a bit of time documenting my findings with regard to rendering of custom fields and in particular the elusive RenderPattern. The Documentation We’ll start with the MSDN documentation since anybody looking to build...
Have you ever thought “it would be really cool if I could create a field control for my publishing page that would interact with all the other field controls"? I’ll bet you have, I know you don’t want to admit it because the idea is madness but I’ll bet you have! (No? I guess I’m out on my own with that one then?) I’ve only really gotten into the latest version of Silverlight in the past few weeks and I have to say I’m impressed. The potential for integration with SharePoint is huge and that’s before we consider the...
I’ve been following a few forum posts about modifying the built-in navigation providers in SharePoint and thought I’d knock up a quick post explaining, step-by-step how this can be done. Unfortunately, the documentation at MSDN is a bit cryptic (Although you’ll see by the end of this article that it makes perfect sense!) As usual, I won’t get into details about creating and deploying features. WSPBuilder is your man. (Although I’m finding SPVisualDev to be a handy wee tool as well these days) So what’s the plan then? On the default master page, you’ll see code...
Ever wanted to be read the Status text displayed on WrkStat.aspx programmatically so that you can make use of it elsewhere? No? Can’t blame you! However, let’s say that you do fancy a bit of masochism. Here’s how it works: The status value is stored in a field of type SPFieldWorkflowStatus. Generally this field has the same display name as your workflow although it’s internal name will be different. Getting the internal name is a pain, for some bizarre reason Microsoft decided to expose this as an internal property rather than public. (See SPWorkflowAssociation.InternalNameStatusField). After...
When developing an application based on SharePoint, a lot of the work goes into packaging and deployment. If you’re working as part of a team this becomes an even bigger problem since you need to be sure that your code can be deployed to each developers machine without causing mayhem and requiring a disproportionate amount of effort (quite literally two steps forward and three steps back!) As it stands at the moment, CAML is a grand idea but it doesn’t go far enough when it comes to packaging complex solutions. It’s my aim to fill in the blanks, making...
This is one of those things that I always forget about and end up having to debug. (Also for those planning to do MCTS, I guarantee that there will be a question about this one ;) ) While it is technically possible to databind to a SPListItemCollection, when you try to refer to any of the SPListItem fields by name you’ll end up with an error similar to this: [ArgumentException: Value does not fall within the expected range.] Microsoft.SharePoint.SPFieldMap.GetColumnNumber(String strFieldName) +161 Microsoft.SharePoint.SPListItemCollection.GetRawValue(String fieldname, Int32 iIndex) +56...
Problem Description When trying to create a new publishing page based on a custom content type you may encounter this error. You’re more likely to see it if you’re trying to save your page to a location other than the default /pages/ document library. Solution This problem occurs when your custom content type definition or your list definition doesn’t reference the base fields required by the publishing infrastructure. In the feature defining your content type and list make sure that you include: <!-- Title Column -->
<FieldRef ID="{fa564e0f-0c70-4ab9-b863-0177e6ddd247}" Name="Title" Required="TRUE" />
...
Problem About 6 weeks ago I set about upgrading a few neglected dev servers to MOSS SP2, the process completed but reported errors similar to the following: Event Type: Error Event Source: SharePoint Products and Technologies Configuration Wizard Event Category: None Event ID: 104 Date: 8/10/2009 Time: 1:49:23 PM User: N/A Computer: MYSERVERNAME Description: ...
Packaging and deployment is often a pain when it comes to SharePoint development. Don’t get me wrong, the infrastructure provided by Microsoft is very powerful and flexible enough to accommodate practically anything but sometimes it doesn’t quite work the way you think it should. One of the key elements of any web site is navigation. More often than not there’s at least one menu bar containing links to other pages within the site. This is one of the areas where SharePoint can be very helpful. Whenever you create a page or any other content, more often than not you’re...
Download the source code for this project here Over the last 2 posts in this series we’ve looked at creating a new field type to handle Xml data. We’ve created a basic implementation and added a custom user interface to make editing the data a bit more friendly. In this article we’ll look at using XSD and XSLT data to provide a higher level of data validation and to give a greater degree of control over how our data is displayed within SharePoint. Previously most of the code that we’ve added has been to the BaseXmlField and SPFieldXmlBase...