Sign Up

Have an account? Sign In Now

Sign In

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask question.

Forgot Password?

Need An Account, Sign Up Here
Sign InSign Up

First independent community of traders

First independent community of traders Logo First independent community of traders Logo

First independent community of traders Navigation

  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • Buy Theme
  • Home
  • About Us
  • Blog
  • Contact Us
Home/ Questions/Q 5405
Next
In Process
krot1941
krot1941

krot1941

  • 1 Question
  • 2 Answers
  • 0 Best Answers
  • 20 Points
View Profile
  • 0
krot1941
Asked: December 29, 20202020-12-29T09:45:28+00:00 2020-12-29T09:45:28+00:00In: Forex Expert Advisors

Script

  • 0

Is it possible to write such a script that when closing an order for example I close an order from the phone the terminal is at home the EA is turned on when closing an order the terminal was also closed?

  • 10 10 Answers
  • 0 Followers
  • 0
Answer
Share
  • Facebook

    10 Answers

    • Voted
    • Oldest
    • Recent
    1. alexeyvik

      alexeyvik

      • 1 Question
      • 74 Answers
      • 0 Best Answers
      • 172 Points
      View Profile
      alexeyvik
      2020-12-29T09:46:23+00:00Added an answer on December 29, 2020 at 9:46 am

      Dmitry Doykov:
      Is it possible to write such a script that when closing an order for example I close an order from the phone the terminal is at home the EA is turned on when closing an order the terminal was also closed?

      Barely found in the bins of old not tested functions… But that was so long ago…. Just for fun posted.

      Method for closing the terminal programmatically.
      As advised by the highly respected Dedushka-this is just what you need at MarginCall.

      #include

      int start()
      {
        int hwnd = WindowHandle(Symbol(), Period());
        int hwnd_parent = 0;

        while(!IsStopped())
         {
           hwnd = GetParent(hwnd);
           if (hwnd == 0) break;
           hwnd_parent = hwnd;
         }

        if(hwnd_parent != 0)
         PostMessageA(hwnd_parent, WM_CLOSE, 0, 0);

        return(0);
      }

      But this is a very old version, may need to be fixed or even no longer works.

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    2. ivanbg

      ivanbg

      • 0 Questions
      • 5 Answers
      • 0 Best Answers
      • 30 Points
      View Profile
      ivanbg
      2020-12-29T09:46:17+00:00Added an answer on December 29, 2020 at 9:46 am

      Dmitry Doykov:
      Is it possible to write such a script that when closing an order for example I close an order from the phone the terminal is at home the EA is turned on when closing an order the terminal was also closed?

      Or maybe it’s better to use expertremove()

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    3. mvs

      mvs

      • 0 Questions
      • 49 Answers
      • 0 Best Answers
      • 136 Points
      View Profile
      mvs
      2020-12-29T09:46:11+00:00Added an answer on December 29, 2020 at 9:46 am

      STARIJ:
      But if the order is closed at SL or TP too close to the terminal? Then you just need the expert to open only one order!!!  And to do it is to freelance

      You can enter the control of the remaining open positions, and if some closed, but there is still in the market, then do not close the terminal, but close only when the last one is closed.

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    4. nektomk

      nektomk

      • 2 Questions
      • 37 Answers
      • 0 Best Answers
      • 90 Points
      View Profile
      nektomk
      2020-12-29T09:46:05+00:00Added an answer on December 29, 2020 at 9:46 am

      Dmitry Doykov:
      And there is no desire to make such? For ₽ or $ ?

      questions about something for money are freelancing.

      and there any thing that can be formulated is possible

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    5. starij

      starij

      • 0 Questions
      • 14 Answers
      • 0 Best Answers
      • 48 Points
      View Profile
      starij
      2020-12-29T09:45:59+00:00Added an answer on December 29, 2020 at 9:45 am

      Dmitry Doykov:
      Is it possible to write such a script that when closing an order for example I close an order from the phone the terminal is at home the EA is turned on when closing an order the terminal was also closed?

      But if the order is closed at SL or TP too close to the terminal? Then you just need the expert to open only one order!!!  And to do it is to freelance

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    6. krot1941

      krot1941

      • 1 Question
      • 2 Answers
      • 0 Best Answers
      • 20 Points
      View Profile
      krot1941
      2020-12-29T09:45:53+00:00Added an answer on December 29, 2020 at 9:45 am

      And there is no desire to make such? For ₽ or $ ?

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    7. alximiks

      alximiks

      • 1 Question
      • 11 Answers
      • 0 Best Answers
      • 52 Points
      View Profile
      alximiks
      2020-12-29T09:45:47+00:00Added an answer on December 29, 2020 at 9:45 am

      Dmitry Doykov:
      Is it possible to write such a script that when closing an order for example I close an order from the phone the terminal is at home the EA is turned on when closing an order the terminal was also closed?

      Execute cannot be pardoned

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    8. artmedia70

      artmedia70

      • 1 Question
      • 41 Answers
      • 0 Best Answers
      • 102 Points
      View Profile
      artmedia70
      2020-12-29T09:45:42+00:00Added an answer on December 29, 2020 at 9:45 am

      Dmitry Doykov:
      What does it mean?

      This is a function whose call from an Expert Advisor or script causes the terminal to close on the tick that follows the function call.

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    9. krot1941

      krot1941

      • 1 Question
      • 2 Answers
      • 0 Best Answers
      • 20 Points
      View Profile
      krot1941
      2020-12-29T09:45:36+00:00Added an answer on December 29, 2020 at 9:45 am

      What does it mean?

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    10. tecciztecatl

      tecciztecatl

      • 0 Questions
      • 10 Answers
      • 0 Best Answers
      • 40 Points
      View Profile
      tecciztecatl
      2020-12-29T09:45:31+00:00Added an answer on December 29, 2020 at 9:45 am

      TerminalClose();

      • 0
      • Reply
      • Share
        Share
        • Share on Facebook
        • Share on Twitter
        • Share on LinkedIn
        • Share on WhatsApp
    Leave an answer

    Leave an answer
    Cancel reply

    Browse

    Sidebar

    Ask A Question

    Stats

    • Questions 504
    • Answers 2k
    • Posts 5
    • Comments 0
    • Best Answers 0
    • Users 681
    • Popular
    • Comments
    • Tags
    • forexcommunity

      Highlighting what’s important about questions & Answers on Discy Community!

      • 0 Comments
    • forexcommunity

      Introducing Keyboard Shortcuts, our first Labs feature

      • 0 Comments
    • forexcommunity

      Defining quality on Discy Engine — what a helpful answer ...

      • 0 Comments
    • forexcommunity

      Organizational and company accounts on Discy Engine the next step

      • 0 Comments
    • forexcommunity

      Hello world!

      • 0 Comments

    Related Questions

    • Brus Agell

      Правельный выбор

      • 0 Answers
    • pinupcasinoo

      Pin Up Casino

      • 0 Answers
    • c00l777

      During optimization, indicators that are not present in the robot ...

      • 2 Answers
    • c00l777

      During optimization, indicators that are not present in the robot ...

      • 0 Answers
    • c00l777

      Optimization results differ on different accounts

      • 3 Answers

    Users

    Leonardcig

    Leonardcig

    • 0 Questions
    • 0 Answers
    DennisByday

    DennisByday

    • 0 Questions
    • 0 Answers
    Haroldmeary

    Haroldmeary

    • 0 Questions
    • 0 Answers

    Footer

    First independent community of traders

    About

    An independent community of forex traders. This is where traders communicate. You can ask your questions and you will receive an answer to your question.
    • Terms of Use
    • Privacy Policy
    • Cookie Policy
    • Knowledge Base
    • Support

    © 2021 Forexcommunity.net. All Rights Reserved