SPEAK

Visual Studio and Sitecore Rocks

Abstract

Developers use Sitecore Rocks when they work with SPEAK.

You use Sitecore Rocks to develop exclusively for SPEAK applications. You cannot use the Content Editor or other related tools. This topic explains how to get started using Sitecore Rocks for SPEAK development.

Sitecore Rocks is a plugin for Visual Studio that you can download. Sitecore Rocks is free, and it is useful for many other Sitecore development tasks.

If you need to connect a SPEAK solution to a Visual Studio project (for example, in order to write server-side C# code), you need both Visual Studio and the plug-in version. If not, you can use the stand-alone version of Sitecore Rocks.

You can use either version of Sitecore Rocks for the following:

If you have a Sitecore installation on your local computer, you must create a connection to the installation before you can use Sitecore Rocks to access it.

Note

You can install Sitecore in different ways. Some third-party automated installers set up a connection and server components as part of the installation so that you do not have to go through the following connection procedure.

To create a connection to a Sitecore installation:

  1. In Sitecore Rocks, in Sitecore Explorer, right-click Connections.

    252F900A8CF749EAA2DA84648254F5AD.png
  2. In the Connection dialog box, in the Host Name field, select the Sitecore installation, and then click OK.

    4223960621A34D1791FEFFB1F75B4640.png
  3. If this dialog appears, click Yes:

    1200435788F34C3987906A46DE47F6FF.png
  4. In the Update Server Components dialog, click Update All:

    E728C83AEF4F4D54AD4CA02246CA9DA5.png

You can now explore a Sitecore installation with the Sitecore Explorer:

2DBEFAB7B5994AB280B46F97ADD3BE35.png

Sitecore is located in the core database. The client folder contains the following folders:

  • Speak – the SPEAK core libraries

  • Your Apps – where you can place your own SPEAK applications

  • Applications – contains Sitecore-developed SPEAK applications

  • Business Component Library and Services – contains SPEAK components

To create a very simple SPEAK page:

  1. Right-click the Your Apps folder and click Add, New Item.

  2. In the Add New Item dialog, select an item template, enter a name for your item, and then click OK:

    CC053BEF65064CF7A01F95AFBB130BB2.png

    Sitecore Rocks creates a page definition item:

    F531E2EE5F9A41A38CE3D60875081601.png
  3. Right-click the item and click Tasks, Design Layout.

    9064F45CA0214A809F4EAF745CBF41E8.png
  4. In the Browse dialog, select a SPEAK layout.

    5166CB4101D9432BBDA719C60D25F5E5.png
  5. In the layout designer, click Add Rendering.

    D9B8C3D950A44DECAE0CA8DEC39CDA21.png
  6. Add these two SPEAK components:

    • PageCode

    • Text

  7. Double-click the Text component and in the Edit Rendering Properties dialog, specify the properties like this:

    772EAC2B4F9C4A0097CA8ED30CCDB91D.png
  8. Click Close, and then click File, Save.

You have now created a very simple SPEAK page, which looks like something like this in a browser:

7F235E01721D4032AF6A2687F9D1E8B7.png