Help with Code in mq4 for fixed Time section? - Page 2
Page 2 of 502 FirstFirst 12
Results 11 to 15 of 15

Thread: Help with Code in mq4 for fixed Time section?

  1. #11
    Quote Originally Posted by ;
    quote For your second greatest find the greatest from the start of the range into the 1st greatest pub and compare with the highest in the 1st greatest pub to the end of the range.
    I can't understand that. I need my glasses

    To discover the second highest, you begin with two vars... h1, and h2. You set them to zero. When you discover a value higher than h2, you set h2 to that value, then you check if the value in h2 is also greater than the value in h1 and when it is you swap the values between h1 and h2. Now you have the best, and second greatest values.

    Or, you simply dump all values in an array and do some type of bulk sorting. That is terribly wasteful.

  2. #12
    Quote Originally Posted by ;
    quote Even I can not understand that. I want my glasses
    Sorry, was a flying trip between digging post holes and mixing concrete, erecting a new garden weapon...

    Imagine the original range for the iHighest was X.... Y the maximum bar was discovered at Z

    Now next Highest is between X and Z and Z and Y, so now execute 2 iHighest calls you from X into Z 1 and one from Z - 1 to Y Evaluate the High values of both bars found and the highest is... the maximum

  3. #13
    Sir
    anybody help me the way to write a code for each week and monthly available. In advance thanks.

  4. #14
    Quote Originally Posted by ;
    sir anybody help me how to write a code to get each week and monthly available. In advance thanks.
    Sorry, but you have to be specific.

  5. #15
    Quote Originally Posted by ;
    Hi Guys How can I code in MT4 fixed Time section. For instance I want from my indi that it will search for a few patterns only from 7:00 to 10:00 GMT and 13:00 to 15:00 GMT. Is for this in mq4 a few function or I must write code for this? Can I use such as TimeCurrent function? But I believe that this will not work because I need fixed time... How I could define that Time section. Thanks for help!!
    Check the http://docs.mql4.com/predefined/variables/time for the bar that you are working on, if it's inside your time range it is possible to populate your buffers, or even within the time range depart the buffers vacant for that bar. If you are working with a timeframe other than the current chart usehttp://docs.mql4.com/series/iTime instead.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
This website uses cookies
We use cookies to store session information to facilitate remembering your login information, to allow you to save website preferences, to personalise content and ads, to provide social media features and to analyse our traffic. We also share information about your use of our site with our social media, advertising and analytics partners more information