My approach. The core is the engine. - page 66

 
Artyom Trishkin:

You're going to sell your hoover on the market after all?

I'm not selling anything. Only for free.

And maybe just for free, without a marketplace. Kodo base or blog...

 
Artyom Trishkin:

In short: for three hundred thousand MAs, do you need three hundred thousand functions? No. You only need one. And it's the same here - different sets of parameters are passed to the same method to produce a different set of results.

Actually, if you use a lot of controls, you don't just throw them onto a form by hand. Arrays of controls are created programmatically. That is, they are indexed. One parameter is added to the function - the element index.

 

Hot Estonian guys.

You can hide a trading technique if it is profitable.

You can hide the technology if it is profitable.

Should we trade this technology, or is it not profitable?

 
Алексей Тарабанов:

Hot Estonian guys.

You can hide a trading technique if it is profitable.

You can hide the technology if it is profitable.

Should we trade this technology, or does it not bring in income?

Happy birthday!

 
Реter Konow:

Well done. Congratulations. ))

You can congratulate yourself and us, when you finally understand that you don't need to write three hundred thousand functions with different parameters, keep them in mind, store them all in arrays, remember where and where everything goes..., but simply create one object that accepts the required number of parameters and create them with a single new operator, even five hundred thousand times. And you can set a different set of parameters for each of them, get a reference to it and work with it individually. You don't have to keep all this mess in your head. One(!!!) object for solving many tasks of the same type with different parameters.

 
Dmitry Fedoseev:

Not somehow, but normally solved.

the problem is set incorrectly, but the solution is normal...

The Expert Advisor is an expert, whose main purpose and goal is to stick to the TS and make money.

In your example, you can change the appearance of EVERYTHING, colours, fonts, windows, dialogues...and there is no need to recompile the combat robot...just put on another skin and go on...

 
Thank you.
 
Реter Konow:

No. Just when the number of element parameters to be changed increases, the complexity of the DLL increases.

Hm, I promised not to log in, but here again I don't understand something )))), has anyone abolished arrays?

I started to write the exchange between dll with a form and MT5, I'm working out the structure today, I will probably create what I want in a couple of days ... Not about that, I am making a structure with buttons and checkboxes in C#

public struct State
        {
                public bool[] button;
                public bool[] checkBox;
                public bool run;
        }

This structure will be filled in by a form in OneClick and on the other side of MT5 will receive similar arrays by call, how many buttons... a couple hundreds, arrays are dynamic, the number of buttons I can put on the form will be the same as the array size .... There's nothing new in C#, everything is convenient and as usually in Windows applications, if memory serves me correctly, I haven't written anything for Windows in 6 or 7 years, I remember everything in half an hour...., I even remembered how to launch the form into a separate thread

SZZ: MT5 developers, respect and respect! They have worked very well with C#! - I have tried to pass a static array to .dll, in C# I can even get the size of an array with this example:

public static void Get(ref int[] arr,ref int sz)
                {
                        sz =arr.Length;
                }

just can't believe that everything works so easy now! ..... didn't think I would say this, but MT5 is the best terminal!!!



Piotr, answer me, have you really never written any program for Windows? Or this forum has become some kind of a psychological experiment where we've all become test subjects?

 
Dmitry Fedoseev:

Actually, usually if you use a lot of controls, you don't just throw them onto a form by hand. Arrays of controls are created by software. That is, they are indexed. One parameter is added to the function - element index.

Well, I cited a simple example. I didn't think Peter was unfamiliar with various MASHES and other terminal things. I should have given him a sample using a chart. But he does not understand it, so it is alien and alienating.

 
Artyom Trishkin:

You can congratulate yourself and us, when you finally realize that you don't need to write three hundred thousand functions with different parameters, keep them in mind, store them all in arrays, remember where and where everything is..., but rather create a single object that accepts the required number of parameters and create them using the same new operator five hundred thousand times. And you can set a different set of parameters for each one of them, get a reference to it and work with it individually. You don't have to keep all this mess in your head. One(!!!) object for solving many tasks of the same type with different parameters.

You would do better to support my solution. It's for Market, for the Community. But you're pulling towards the DLL...