iSpring.Skins Interface

The Skins Interface represents a collection of available player skins. It provides the information about skins and allows adding customized skins. The Skins Interface exposes the following properties and methods.

Table 1. Properties
Property Value Type Access Default value Property description
Count int Read only   Returns number of skins in the collection
Table 2. Methods
Method Method description
Skin Item(object skinIndex)

Returns the Skin interface representing a skin with a given skin index. The skinIndex parameter can be one of the following types:

  • an integer value specifying skin order number. Note: order number is 1-based
  • a string specifying skin name, id or alias. Skin id, name and alias are specified in the .skin XML files in the {iSpringSDK installation folder}\players folder.

Note: This is a default method of the Skins interface so it can be omitted in some programming languages such as Visual Basic or C#. See the Samples section for more details.

void Load(string path) Loads additional player skin or skins from the specified path. Note: if the path parameter is a folder name, it will be searched for *.skin files. If the path parameter is a file name, the specified skin file name will be loaded.


The following samples illustrate typical tasks which can be performed using the Skins interface.

C# sample

PresentationConverter pc = new PresentationConverter();
Skins skins = pc.Skins;

// the following ways can be used to access individual skins of the collection
Skin skin1 = skins[1];
Skin skin2 = skins.Item(2);
Skin nullSkin = skins["NullSkin"];
Skin crystalSkin = skins["Crystal"];

// load one skin file
skins.Load("c:\\my skins\\");

// load skin files using wildcard
skins.Load("c:\\all skins\\skin*.skin");

// load all .skin files in c:\myskins folder

// Enumerate the installed skins
foreach (Skin skin in skin){    Console.WriteLine(        "Skin \t" + "name: \"" + skin.Name + "\", id: \"" + skin.Id + "\"\n" +        "\t" + "alias: \"" + skin.Alias + "\", Flash Player Version: " + skin.SwfVersion        );}

VB.NET sample:

Dim pc as new PresentationConverter()

' the following ways can be used to access individual skins of the Skins collection
Dim skins as Skins = pc.Skins
Dim skin1 as Skin = skins(1)
Dim skin2 as Skin = skins(2)
Dim nullSkin as Skin = skins("NullSkin")
Dim advancedSkin as Skin = skins.Item("Advanced")

// load one skin file
skins.Load("c:\my skins\")

// load skin files using wildcard
skins.Load("c:\all skins\skin*.skin")

// load all .skin files in c:\myskins folder