Change top left SharePoint text

How to change the top left text in your SharePoint site.

Adjust the script below to fit your needs. Start the SharePoint Management Shell and run your adjusted script. Done!

$webApp = Get-SPWebApplication http://nuc

$webApp.SuiteBarBrandingElementHtml = "<div style='padding-left:12px'><a href='http://nuc/' style='color:white' title='Go to the Start page'>Our Home Site</a></div>"


SPWebApplication.SuiteBarBrandingElementHtml property

Change Authentication Method for your web project in Visual Studio 2013

So, you want to change the authentication method for your Visual Studio 2013 Web project? Well, once you find where to do it, it is easy.

Iin the Solution Explorer Window, select your project and press the F4 button. Now you can change the Anonymous and Windows Authentication methods.

Select the project and press F4


Change the Anonymous and Windows Authentication methods according to your demands.


Add SharePoint List row by posting a Soap Envelope

Example showing how to do a POST to a SharePoint list from a .NET web application. The purpose of the POST is to add a new row in a specific SharePoint list. 

In this example the list has three columns;

  1. Title, Single line of text
  2. MeasuredValue, Number
  3. TimeStamp, Date and Time

Parameters to adjust in the code sample;

  • listGUID
  • listURI
  • NetWorkCredential, YourADUserName, YourADPassword and YourDomain


Code sample:

    Sub AddListRow()

        Dim Title As String = "Snowing"

        Dim MeasuredValue As String = "-2.3"

        Dim TimeStamp As DateTime = DateTime.Now

        Dim listGUID As String = "{0600A25B-2FFC-43B0-8AF9-7E73AA9013DA}"

        Dim listURI As String = "http://YourSharePointUrl/_vti_bin/lists.asmx"


        Dim soapEnvelope As New StringBuilder

        With soapEnvelope

            .AppendLine("<soap12:Envelope xmlns:xsi="""" xmlns:xsd="""" xmlns:soap12="""">")


            .AppendLine("<UpdateListItems xmlns="""">")

            .AppendLine(String.Format("<listName>{0}</listName>", listGUID))



            .AppendLine("<Method ID=""1"" Cmd=""New"">")

            .AppendLine(String.Format("<Field Name=""Title"">{0}</Field>", Title))

            .AppendLine(String.Format("<Field Name=""MeasuredValue"">{0}</Field>", MeasuredValue))

            .AppendLine(String.Format("<Field Name=""TimeStamp"">{0}</Field>", TimeStamp))







        End With



        Dim client As New WebClient()

        With client

            .Credentials = New NetworkCredential("YourADUserName", "YourADPassword", "YourDomain")

            .Headers("SOAPAction") = ""

            .Headers("Content-Type") = "application/soap+xml; charset=utf-8"

            .Encoding = Encoding.UTF8

        End With



        Dim response As String = client.UploadString(New Uri(listURI, UriKind.Absolute), "POST", soapEnvelope.ToString)


        wcResult.Text = response


    End Sub

SharePoint Tools

A list of useful tools for managing SharePoint.

SharePoint Manager 2013 (2010)

The SharePoint Manager 2013 is a SharePoint object model explorer. It enables you to browse every site on the local farm and view every property.
SharePoint 2010 Version:

Stramit SharePoint Caml Viewer

Tool to help you write a correct CAML Query.

SharePoint CAML Query Helper

Use this program to help build and test SharePoint CAML Queries (Collaborative Application Markup Language). Compatible with WSS 3.0, MOSS 2007, Foundation 2010, SharePoint 2010, and now SharePoint 2013.


SPServices is a jQuery library which abstracts SharePoint's Web Services and makes them easier to use. It also includes functions which use the various Web Service operations to provide more useful (and cool) capabilities. It works entirely client side and requires no server install.

Boot Disk Utilities

Some great utilities tools to help you create boot disks.

Rufus is a small utility that helps format and create bootable USB flash drives, such as USB keys/pendrives, memory sticks, etc

UNetbootin allows you to create bootable Live USB drives for Ubuntu, Fedora, and other Linux distributions without burning a CD.

Windows 7USB/DVD Download Tool
The Windows 7 USB/DVD Download tool allows you to create a copy of your Windows ISO file on a USB flash drive or a DVD. To create a bootable DVD or USB flash drive, download the ISO file and then run the Windows 7 USB/DVD Download tool. Once this is done, you can install Windows directly from the USB flash drive or DVD.

The product key entered does not match

Windows 8 or Windows Server 2012 installation may fail with error message: The product key entered does not match any of the Windows images available for installation. Enter a different product key

This problem can occur if the supplied product key does not match the media that is being used to install Windows. The supplied product key may be in an unattended file, in the EI.CFG file, in the PID.txt file or in the firmware of the BIOS. Windows 8 OEM machines ship with the product key in the firmware, and if that product key does not match the media then you will see the error message from above. For example: Installing a Windows Server 2012 on a Windows 8 OEM machine is likely to cause this problem.


Use notepad or similat to make a file called PID.txt and put the following in the file:


Place your windows 8 or Server 2012 key in where the X's are and save the file to the /sources directory in the root of your USB key.

The PID file overrides the pre-installed OEM key in the bios of your computer. Windows 8 or Server 2012 installation starts right up.

Loop DataTable

How to loop items in a DataTable

        Dim sbTable As New StringBuilder

        Dim DT As DataTable = DS.Tables("Meta") 'Get your DataTable somehow

        Dim y As Integer = 0

        Dim n As Integer = 0

        sbTable.Append("<table border=""1"">")


        For y = 0 To DT.Columns.Count - 1

            sbTable.Append("<th>" & HttpUtility.HtmlEncode(DT.Columns.Item(y).ColumnName) & "</th>")



        For n = 0 To DT.Rows.Count - 1


            For y = 0 To DT.Columns.Count - 1

                sbTable.Append("<td>" & HttpUtility.HtmlEncode(DT.Rows(n).Item(y)) & "</td>")





Read AppSettings in web.config

How to read appSettings values from web.config.


    <add key="KeyName" value="The value here"/>



Dim s As String = System.Configuration.ConfigurationManager.AppSettings("KeyName")

Css and JavaScript Urls

Including javascript and css can be a pain if not all pages are placed in the same paths relative to the css and javascript files. Here's a way to avoid the problem.

    <link id="common-css" runat="server" href="~/css/common.css" rel="stylesheet" />

    <script src="<%= ResolveUrl("~/js/jquery-1.9.1.min.js")%>" type="text/javascript"></script>

Embedded Code Blocks in ASP.NET Web Pages

An embedded code block is server code that executes during the page's render phase. The code in the block can execute programming statements and call functions in the current page class. The following code example shows an ASP.NET page with an embedded code block.

<%@ Page Language="VB" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">

<html xmlns="" >


    <title>Hello World!</title>

    <style type="text/css">



        font-family: Verdana, Sans-Serif;

        font-size: 0.8em;






<script runat="server">


    Public myVar As String = String.Empty

    Private myString As String = String.Empty


    Sub Page_Load()

        myVar = "Some value..."

        Call MySub()

    End Sub


    Sub MySub()

        myString = "This is my string!"

    End Sub




<% Response.Write(DateTime.Now())%>

<hr />


<hr />