Plug-in License issue
Plug-in License issue
Hello,
I have a composite application in WPF (.Net 3.5). Basically its a UI container which displays various plugins.
My plug-in dll is the one that uses TeeChart.
The problem is : when i try to execute my application on a machine that does not have tee chart installed on it, i get the license exception.
I tried using the contructor for plug-in license mentioned in the help files. But its doesn't work. If i add the teechart license to the license.licx of my
container dll, things work fine. But its something i cannot afford to do. Im wondering why the plug-in license contructor doesn't work.
Is there a special requirement for it? my container dll does not make calls to the teechart.
Thanks.
Freddie
I have a composite application in WPF (.Net 3.5). Basically its a UI container which displays various plugins.
My plug-in dll is the one that uses TeeChart.
The problem is : when i try to execute my application on a machine that does not have tee chart installed on it, i get the license exception.
I tried using the contructor for plug-in license mentioned in the help files. But its doesn't work. If i add the teechart license to the license.licx of my
container dll, things work fine. But its something i cannot afford to do. Im wondering why the plug-in license contructor doesn't work.
Is there a special requirement for it? my container dll does not make calls to the teechart.
Thanks.
Freddie
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Re: Plug-in License issue
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Plug-in License issue
Hi Narcís,
Yes, this is what i have been referring to in the TeeChart help file aswell.
But somehow, its just not working out for me.
Let me explain the scenario, its a composite application, meaning that i have a UI container which has a panel.
The UI container dynamically loads my dll containing the TeeChart, lets call it dummy.dll
This dummy.dll contains user control containing TeeChart. The moment i click on the button which causes this usercontrol from dummy.dll to be
displayed, i get a license exception.
Even if i implement the following :
Steema.TeeChart.TChart tempChart = new Steema.TeeChart.TChart(this);
tempChart = null;
InitializeComponent(); //
in my USER CONTROL'S CONTRUCTOR. It doesn't work. Is it the right way to go about it?
Im not sure, since the dll has already been loaded, its just that when i execute the command for displaying the user control , that's when the TeeChart is
created and i get the exception.
Loading of the module using Assembly.Load causes no issues.
Thanks for your help, much appreciated.
Freddie
Yes, this is what i have been referring to in the TeeChart help file aswell.
But somehow, its just not working out for me.
Let me explain the scenario, its a composite application, meaning that i have a UI container which has a panel.
The UI container dynamically loads my dll containing the TeeChart, lets call it dummy.dll
This dummy.dll contains user control containing TeeChart. The moment i click on the button which causes this usercontrol from dummy.dll to be
displayed, i get a license exception.
Even if i implement the following :
Steema.TeeChart.TChart tempChart = new Steema.TeeChart.TChart(this);
tempChart = null;
InitializeComponent(); //
in my USER CONTROL'S CONTRUCTOR. It doesn't work. Is it the right way to go about it?
Im not sure, since the dll has already been loaded, its just that when i execute the command for displaying the user control , that's when the TeeChart is
created and i get the exception.
Loading of the module using Assembly.Load causes no issues.
Thanks for your help, much appreciated.
Freddie
Re: Plug-in License issue
Hi,
I have implemented a sample app as per the help file.
It follows the exact steps given in the TeeChart help for executing a plugin dll.
I still get a license exception.
Could someone please help me with this as its very important for the upcomign release of our product.
Thanks.
Freddie
I have implemented a sample app as per the help file.
It follows the exact steps given in the TeeChart help for executing a plugin dll.
I still get a license exception.
Could someone please help me with this as its very important for the upcomign release of our product.
Thanks.
Freddie
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Re: Plug-in License issue
Hi Freddie,
The plugin technique works if your client application, the one housing the UI Panel, doesn't make reference to TeeChart directly, ie. that no button or like method in the app calls a TeeChart method or sets a TeeChart property. The plugin needs to be independant in that sense.
For a fully working example project please see: http://www.teechart.net/files/public/su ... Steema.zip (you may need to change references to the location of the latest version of teechart.dll).
The plugin technique works if your client application, the one housing the UI Panel, doesn't make reference to TeeChart directly, ie. that no button or like method in the app calls a TeeChart method or sets a TeeChart property. The plugin needs to be independant in that sense.
For a fully working example project please see: http://www.teechart.net/files/public/su ... Steema.zip (you may need to change references to the location of the latest version of teechart.dll).
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Plug-in License issue
Thanks Narcis, i will be looking at the sample.
Is this valid for the WPF version aswell?
Im working with TeeChart.WPF.dll.
Thanks.
Is this valid for the WPF version aswell?
Im working with TeeChart.WPF.dll.
Thanks.
Re: Plug-in License issue
Sorry for double post. But here's my sample app. Could you please help me identify the goof-up.
Thanks,
Freddie
Thanks,
Freddie
- Attachments
-
- License Issue.zip
- (66.32 KiB) Downloaded 338 times
Re: Plug-in License issue
Hello Freddie,
Your example is largely correctly setup. There's a couple of small changes you'll need to make. Here's an example of a constructor for the Usercontrol that permits the licensing to work correctly:
Note that the TeeChart constructor is taking the UserControl as argument, not the executing assembly. That allows the Usercontrol to ratify licensing independantly to that of the host application (that itself may not be aware of TeeChart).
Regards,
Marc Meumann
Your example is largely correctly setup. There's a couple of small changes you'll need to make. Here's an example of a constructor for the Usercontrol that permits the licensing to work correctly:
Code: Select all
public UserControl1()
{
Steema.TeeChart.WPF.Chart chart = new Steema.TeeChart.WPF.Chart(this);
chart = null;
InitializeComponent();
}
Regards,
Marc Meumann
Steema Support
Re: Plug-in License issue
Thanks for the response Marc.
Finally we have figured the problem, and its unbelievably silly.
The help file says :
Form:
namespace PluginWithTeeChart
{
public partial class FormWithChart : Form
{
public FormWithChart()
{
//discardable Chart forces License check
Steema.TeeChart.TChart tempChart = new Steema.TeeChart.TChart(this);
tempChart = null;
InitializeComponent(); //<---- Normal application code. Could run here various TeeCharts without need for overloaded constructor
}
}
}
And this is what we had been trying all these days !! However, it doesn't work, it works when i use 'Chart' instead of a 'TChart' class.
And since the help file says so, we had a completely frustrating time figuring this one out.
Regards.
Freddie
Finally we have figured the problem, and its unbelievably silly.
The help file says :
Form:
namespace PluginWithTeeChart
{
public partial class FormWithChart : Form
{
public FormWithChart()
{
//discardable Chart forces License check
Steema.TeeChart.TChart tempChart = new Steema.TeeChart.TChart(this);
tempChart = null;
InitializeComponent(); //<---- Normal application code. Could run here various TeeCharts without need for overloaded constructor
}
}
}
And this is what we had been trying all these days !! However, it doesn't work, it works when i use 'Chart' instead of a 'TChart' class.
And since the help file says so, we had a completely frustrating time figuring this one out.
Regards.
Freddie
Re: Plug-in License issue
Hello Freddie,
Yes; TChart works if you are using a TChart, for a Steema.TeeChart.Chart use Steema.TeeChart.Chart and for WPF.Chart you should use a WPF.Chart (as indeed you did in the example you sent through). Besides that the key point to note would be that as mentioned a couple of posts back, that one should pass the Plugin's assembly to the Chart constructor (rather than the executing assembly).
Thanks for your feedback, we'll add a note to the documentation.
Regards!
Marc
Yes; TChart works if you are using a TChart, for a Steema.TeeChart.Chart use Steema.TeeChart.Chart and for WPF.Chart you should use a WPF.Chart (as indeed you did in the example you sent through). Besides that the key point to note would be that as mentioned a couple of posts back, that one should pass the Plugin's assembly to the Chart constructor (rather than the executing assembly).
Thanks for your feedback, we'll add a note to the documentation.
Regards!
Marc
Steema Support
Re: Plug-in License issue
Hello Marc,
Actually i did try to pass the plugin assembly as a parameter aswell, but i did not work.
I have read the documentation multiple times and tried multiple permutations and combinations, however, none of them
seemed to work with TChart class.
The Chart class works.
Thanks,
Freddie.
Actually i did try to pass the plugin assembly as a parameter aswell, but i did not work.
I have read the documentation multiple times and tried multiple permutations and combinations, however, none of them
seemed to work with TChart class.
The Chart class works.
Thanks,
Freddie.