Featured Post

JQuery and SPServices

JQuery and SPServices      ‘Sup All…I’m going to be covering the use of JQuery and SPServices in this article.   JQuery is a librar...

Thursday, June 16, 2011

Create a Diagram/Picture Viewer Page in SharePoint

Setup Data Source

1.       Select the Picture library you’d like to reference
2.       Insert the selected library as a Data Source Control


3.       Setup two (2) Data Views
a.       Setup the first Data View using the ‘Title’ field (or whichever field you’d like to use)

b.      Setup the second Data View using the ‘Preview’ field
4.       You’ll have to do very minor coding here (if you can even call it that). Find the following line:
<td class="ms-vb">
                <xsl:value-of select="@Preview"/>
                </td>

5.       Add the following image tag (in red):
<td class="ms-vb">
                <xsl:value-of select="@Preview"/><img alt="thumbnail" src="{@FileRef}" />
                </td>

6.       At this point you may feel free to delete the <xsl:value-of select="@Preview"/>


7.       This is how your page should look (with a little added formatting to left justify the headings):

When you click the name hyperlink, the diagram will change:



Tuesday, June 14, 2011

Build Reusable Emails In SharePoint

Background

You want to be able to save an HTML formatted email to use in a workflow without having to modify that workflow every time you need to modify the language.

Solution

Create a list keep the title field and create a multiline field. The Title field will hold the value you will match with in your workflow and the multiline field will hold your HTML email text.

Detailed Solution Steps

1.       Create a list with the Title field and a Multiline field


2.       Populate the Title field with a value that is easy to remember for the task at hand and populate the Multiline text field with the HTML message that you want to use. I suggest making separate pieces (i.e. Header, Body, Footer, etc).

Create Your Workflow
When creating your workflow, you may now reference the email message value utilizing the Title field value.
1.       Example: Create a workflow that sends an email message
2.       Build your message using the Build Dynamic String function

3.       Reference the stored email messages utilizing the Title field

4.       Store the values into meaningful variable names

5.       Build your email message


6.       When the workflow is run (I’m running it from an issue list that will also include the message that the sender types into the description field) the email message will be built.





7.       The resulting email will look similar to this