Table of Contents

Property Strings

Namespace
Alternet.Editor.TextSource
Assembly
Alternet.Editor.v9.dll

Strings

Gets or sets text source content in the form of string array.

[TypeConverter(typeof(CollectionConverter))]
public virtual string[] Strings { get; set; }

Property Value

string[]

Examples

Here is how to use a Strings in the C# code:

using System;

using Alternet.Editor;
using Alternet.Editor.TextSource;

public partial class Form1 : Form
{
    private TextSource textSource;
    private void Form1_Load(object sender, EventArgs e)
    {
        var syntaxEdit = new SyntaxEdit(this.components);
        textSource = new TextSource(this.components);
        textSource.Strings = new string[] { "first string", "second string", "third string" };

        syntaxEdit.Source = this.textSource;
    }
}

Here is how to use a Strings in the Visual Basic code:

Imports System

Imports Alternet.Editor
Imports Alternet.Editor.TextSource

Partial Public Class Form1
    Inherits Form

    Private textSource As TextSource

    Private Sub Form1_Load(ByVal sender As Object, ByVal e As EventArgs)
        Dim syntaxEdit = New SyntaxEdit(Me.components)
        textSource = New TextSource(Me.components)
        textSource.Strings = New String() {"first string", "second string", "third string"}

        syntaxEdit.Source = Me.textSource
    End Sub
End Class

Remarks

Each item in the list represents an individual text line stored by the TextSource object.