If we add class, error : Class1 not defined  [SOLVED]

Questions about MultiCharts .NET and user contributed studies.
Emmanuel
Posts: 287
Joined: 21 May 2009
Has thanked: 68 times
Been thanked: 19 times

If we add class, error : Class1 not defined

Postby Emmanuel » 02 Aug 2012

Hi,

How do you add a module or a class ?

In Visual Studio, If I add a Class in a an indicator , I get the message in the powerlanguage .NET editor :

"Class1 not defined"

How do i declare it in VS ?

Emmanuel

Dru
Posts: 107
Joined: 28 Aug 2007
Has thanked: 4 times
Been thanked: 170 times

Re: If we add class, error : Class1 not defined  [SOLVED]

Postby Dru » 03 Aug 2012

Emmanuel wrote:Hi,

How do you add a module or a class ?

In Visual Studio, If I add a Class in a an indicator , I get the message in the powerlanguage .NET editor :

"Class1 not defined"

How do i declare it in VS ?

Emmanuel

The format of the study file name is:TechName.TechType.cs(vb) where:
1) TechName - the name of the study (must be equal to class name).
2) TechType - type of the study (Indicator, Strategy, Function)

When the new file with name that matches this template is created, MC will "pick up" it as new study.
These users thanked the author Dru for the post (total 3):
EmmanuelStan BokovDave Masalov

Emmanuel
Posts: 287
Joined: 21 May 2009
Has thanked: 68 times
Been thanked: 19 times

Re: If we add class, error : Class1 not defined

Postby Emmanuel » 03 Aug 2012

Hi Dru

This is really interesting, It work !!!

I created a second indicator (a second class), then load this second indicator in the sub new of the first indicator.

This is cool !!!

Thanks

Emmanuel


Return to “MultiCharts .NET”