Show / Hide Table of Contents

License Registration

When you buy a commercial version of ThermalLabel you are provided with license information to register your licensed copy of Neodynamic ThermalLabel SDK for .NET and the Visual Editors Add-On.

Registering ThermalLabel SDK

ThermalLabel SDK in Windows Projects

In the class where you're using ThermalLabel SDK, set the LicenseOwner and LicenseKey static (shared in VB) properties with the license info you've received.

Important

Please, keep in mind that the license info is case-sensitive!

VB

' WINDOWS FORMS SAMPLE

Imports Neodynamic.SDK.Printing

Public Class Form1

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

        ThermalLabel.LicenseOwner = "LICENSE-OWNER-FOR-SDK"
        ThermalLabel.LicenseKey = "LICENSE-KEY-FOR-SDK"

    End Sub

End Class

C#

// WINDOWS FORMS SAMPLE

using Neodynamic.SDK.Printing;

public partial class Form1 : Form
{
    private void Form1_Load(object sender, EventArgs e)
    {
        ThermalLabel.LicenseOwner = "LICENSE-OWNER-FOR-SDK";
        ThermalLabel.LicenseKey = "LICENSE-KEY-FOR-SDK";
    }
}

ThermalLabel SDK in ASP.NET WebPrintJob Scenarios

If you're using ThermalLabel in ASP.NET by creating WebPrintJob objects, then license info must be set to the LicenseOwner and LicenseKey properties of WebPrintJob class.

Important

Please, keep in mind that the license info is case-sensitive!

VB

Protected Sub Page_Init(sender As Object, e As System.EventArgs) Handles Me.Init

        'is this a request for a WebPrintJob handler?
        If Not Request("webPrintJob") Is Nothing Then
            'Create a WebPrintJob obj 
            Dim webPj As New WebPrintJob()

            'Set License Info
            webPj.LicenseOwner = "LICENSE-OWNER-FOR-SDK"
            webPj.LicenseKey = "LICENSE-KEY-FOR-SDK"

            'set a ThermalLabel obj 
            webPj.ThermalLabel = GenerateBasicThermalLabel()

            '...

        End If

End Sub

C#

protected void Page_Init(object sender, EventArgs e)
{
    //is this a request for a WebPrintJob handler?
    if (Request["webPrintJob"] != null)
    {
        //Create a WebPrintJob obj 
        WebPrintJob webPj = new WebPrintJob();

        //Set License Info
        webPj.LicenseOwner = "LICENSE-OWNER-FOR-SDK";
        webPj.LicenseKey = "LICENSE-KEY-FOR-SDK";

        //set a ThermalLabel obj 
        webPj.ThermalLabel = GenerateBasicThermalLabel();

        //... 

    }
}

Registering ThermalLabel Visual Editor for Windows

In the class where you're using the ThermalLabel Visual Editor, set the LicenseOwner and LicenseKey static (shared in VB) properties with the license info you've received.

Important

Please, keep in mind that the license info is case-sensitive!

Note

You will also need to Register the ThermalLabel SDK

VB

' WINDOWS FORMS SAMPLE

Imports Neodynamic.Windows.Forms.ThermalLabelEditor

Public Class Form1

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

        ThermalLabelEditor.LicenseOwner = "LICENSE-OWNER-FOR-EDITOR"
        ThermalLabelEditor.LicenseKey = "LICENSE-KEY-FOR-EDITOR"

    End Sub

End Class

C#

// WINDOWS FORMS SAMPLE

using Neodynamic.Windows.Forms.ThermalLabelEditor;

public partial class Form1 : Form
{
    private void Form1_Load(object sender, EventArgs e)
    {
        ThermalLabelEditor.LicenseOwner = "LICENSE-OWNER-FOR-EDITOR";
        ThermalLabelEditor.LicenseKey = "LICENSE-KEY-FOR-EDITOR";
    }
}

Registering ThermalLabel Web Editor for ASP.NET

In the class where you're using the ThermalLabelWebEditor class, set the License... static (shared in VB) properties with the license info you've received.

Important

Please, keep in mind that the license info is case-sensitive!

VB

' MVC SAMPLE
Imports Neodynamic.Web.ThermalLabelEditor

Public Class ThermalLabelWebEditorHandlerController
    Inherits System.Web.Mvc.Controller

    Sub ProcessRequest()

        Try

            'Set license info for Web Editor and SDK
            ThermalLabelWebEditor.LicenseOwnerForEditor = "LICENSE OWNER FOR WEB EDITOR HERE"
            ThermalLabelWebEditor.LicenseKeyForEditor = "LICENSE KEY FOR WEB EDITOR HERE"
            ThermalLabelWebEditor.LicenseOwnerForSDK = "LICENSE OWNER FOR SDK HERE"
            ThermalLabelWebEditor.LicenseKeyForSDK = "LICENSE KEY FOR SDK HERE"

            '...

        Catch ex As Exception
            '...
        End Try

    End Sub

End Class

C#

// MVC SAMPLE

using Neodynamic.Web.ThermalLabelEditor;

public class ThermalLabelWebEditorHandlerController : Controller
{
    public void ProcessRequest()
    {
        try
        {
            //Set license info for Web Editor and SDK
            ThermalLabelWebEditor.LicenseOwnerForEditor = "LICENSE OWNER FOR WEB EDITOR HERE";
            ThermalLabelWebEditor.LicenseKeyForEditor = "LICENSE KEY FOR WEB EDITOR HERE";
            ThermalLabelWebEditor.LicenseOwnerForSDK = "LICENSE OWNER FOR SDK HERE";
            ThermalLabelWebEditor.LicenseKeyForSDK = "LICENSE KEY FOR SDK HERE";

            //...
        }
        catch (Exception ex)
        {
            //...
        }

    }
}
Back to top Copyright © 2003- Neodynamic SRL
http://www.neodynamic.com