Q6101010. How to manually add a Chart FX license to an executable

The information on this article applies to
Summary

This article describes a procedure that could potentially breach the Chart FX for .NET License agreement (Sections 3. REDISTRIBUTABLE CODE and 4. DISTRIBUTION REQUIREMENTS). Please contact Software FX to discuss your specific needs of wrapping ChartFX for .NET and to obtain authorization to do so.

In some situations, license information needs to be manually included into application using licensed controls. This article explains when and how to do it.

Description
Using licensed controls and components in .NET is very transparent in most situations, Visual Studio .NET and the .NET framework work in unison to take all the necessary steps to make it work. The following link points to an article on how licensing works in .NET, it describes in detail how licensing is implemented and the tools and classes involved in the process, it makes a good reading for people building or using licensed controls (like Chart FX), components or classes.

http://www.gotdotnet.com/team/windowsforms/Licensing.aspx

How does all this affects you as a Chart FX for .NET user ?
If you are building a stand-alone application where the charts are created at design time, you don't have to do anything especial.
You do need to take additional steps in the following cases:

- You are building a DLL that uses Chart FX for .NET, this DLL is then used by an application (EXE).
- You are creating all of your charts at run-time, purely by code.
- You are using a tool or language that has no support for Design Time licensing, for example Managed C++

If you are in one of these scenarios, you must embed the license information of Chart FX for .NET as follows:

1) If your project does NOT have a Licenses.licx file in your project, add an empty one (text file).

2) Add the following line to it:

SoftwareFX.ChartFX.Chart, ChartFX

3) If you are using Visual Studio .NET and your application is written in C# or VB simply re-build your executable, otherwise (if you are not using VS .NET or if you are using Managed C++) continue to step 4.

4) Execute the following command from the folder in which your executable, ChartFX.dll, ChartFX.Base.dll and licenses.licx reside:

lc /target:<Name of your Executable.exe> /complist:licenses.licx /i:ChartFX.DLL

A .licenses file will be created in the same folder.

Note: If you use other licensed controls, components or classes in your application you must include a reference to EACH DLL using /i and a line in licenses.licx for every licensed class.

5) Embed this .licenses file as a resource into your executable, you can do this at linking time by using the /ASSEMBLYRESOURCE option. If you are using Visual Studio you can embed this file by going to the Linker properties and adding the reference under "Embed Managed Resource File" (Input category).

6) Test your application by running it in a computer where Chart FX is not installed.

Related Articles
Q6101001 How to deploy a WinForms Application when it contains a wrapper object using Chart FX for .NET
Q6101008 Using Chart FX for .NET Windows Forms control from a DLL
Q6101016 Issues migrating Chart FX for .NET (Windows Forms) from the trial version to a licensed version
Q6101017 Licensing issues related to using Chart FX for .NET extensions with an existing version of the core product


ArticleID:Q6101010
Keywords:
Reviewed:11/23/2006 10:26:00 AM

DISCLAIMER INFORMATION:
Information in this document is subject to change without notice and does not represent a commitment on the part of Software FX, Inc. The software, which includes the information contained in any databases, described in this document is furnished under a license agreement or nondisclosure agreement. The software may be used or copied only in accordance with the terms of those agreements. It is against the law to copy the software on any medium except as copy of the software for backup purposes. No part of this article may be reproduced or transmitted in any form or by any means including recording, or information storage and retrieval systems, for any purpose other than the purchaser's personal use, without the express written permission of Software FX, Inc.

Software FX, Inc. disclaim all warranties, either express or implied, including but not limited to implied warranties of merchantability and fitness for a particular purpose, with respect to the instructions contained in this article.

In no event shall Software FX, Inc. be liable for any damages whatsoever including, without limitation, damages for loss of business profits, business interruption, loss of business information, or other pecuniary loss, even if Software FX, Inc. has been advised of the possibility of such damages. Because some states do not allow the exclusion or limitation of liability for consequential or incidental damages, the above limitation may not apply to you.