¿Puedo controlar mediante programación el número de cuenta al crear una nueva cuenta en MetaTrader 4?

StackOverflow https://stackoverflow.com/questions/4546642

  •  13-10-2019
  •  | 
  •  

Pregunta

Tengo un plug-in ++ C para MetaTrader 4 que me permite crear nuevas cuentas en ella para el comercio de los propósitos. Me gustaría ser capaz de dictar a MT4 el número de cuenta al crear la nueva cuenta. Podría Cualquiera sabe si esto es posible y cómo podría hacerse?

¿Fue útil?

Solución

You can specify the account number in the login field of the UserRecord struct your are using in the call to UserRecordNew method. If the account already exits you will get an error from the method as apposed to RET_Ok.

Otros consejos

The account number is generated by the broker upon account creation - So the simple answer is No; you cannot control it. The only way would be to generate an account number, and based on it anticipate what the next account number will be. This is only possible if the account number algorithm is broker-specific. This would surprise me though. I am willing to bet that account numbers are generated by MetaQuotes server with a one-way-function.

If you use any API, you can manually enter the account number. If the specified account number exists, the system will reject your request. Is there any particular reason you want to enter custom numbers while opening the account?

It is not possible to control the account number. The justification of this is the fact that the account number is developed by the broker upon the opening of an account.The only way that this would be possible would be if one was to generate an account number and use this number to anticipate what the next account number will be. This approach is however, possible if the account number algorithm is broker-specific.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top