TheSnowGuru / PyTrader-python-mt4-mt5-trading-api-connector-drag-n-drop

Open Source Trading Strategies & End-to-End solution connecting Metatrader4 & Metatrader5 💹 with Python with a simple drag and drop EA. Fully tested bug free & efficient solution for live & paper trading⭐ Full Documentation ready. Lightweight, efficient and stable implementation 🔥
https://discord.gg/wRMUNP8ERa
653 stars 11 forks source link

How can I connect my demo account #25

Closed Near-Tam closed 11 months ago

Near-Tam commented 2 years ago

I found that there is no server ip in my demo account. How can I connect my demo account base on this situation.

Branly76 commented 2 years ago

Hi,

Not exactly clear what you mean. You move the MT4/MT5 EA into a chart. On the upper right side of the chart you will have a happy face and on the upper left side demo or licensed. On this machine/pc the IP address will be 127.0.0.1. If your python script is on the same machine/pc then use 127.0.0.1 as IP and the socket number as seen in the MT ea in the connect function.

If not clear, lets chat by the discord channel.

BR Huub

Near-Tam commented 2 years ago

when I was ran the Python_script_example_PyTrader.py file it return an error: Couldnt connect with the socket-server: [Errno 61] Connection refusedelf.sock terminating program False Traceback (most recent call last): File "Python_script_example_PyTrader.py", line 95, in CheckAlive = MT.Check_connection() File "/Users/neablister/PycharmProjects/PyTrader-python-mt4-mt5-trading-api-connector-drag-n-drop/Pytrader_API_V2_08.py", line 208, in Check_connection ok, dataString = self.send_command(self.command) File "/Users/neablister/PycharmProjects/PyTrader-python-mt4-mt5-trading-api-connector-drag-n-drop/Pytrader_API_V2_08.py", line 1825, in send_command self.sock.send(bytes(self.command, "utf-8")) BrokenPipeError: [Errno 32] Broken pipe

How can I fix it ?

Branly76 commented 2 years ago

Do you have the MT4/5 EA running in a metatrader terminal. Licensed or demo does not matter.

afbeelding

Near-Tam commented 2 years ago

like this?

image
Branly76 commented 2 years ago

You need to have the MT4/5 EA in only one chart. afbeelding

Watch the red arrows, do you have the info above in your chart.

BR

Branly76 commented 2 years ago

I wrote a lot of documentation, did you read this .pdf. ??? BR

Near-Tam commented 2 years ago

Thx, I'll read it now.

Branly76 commented 2 years ago

You can also contact me on discord, chatting is much easier. BR