記事"MQL5言語でのTelegram用ボットの作成"についてのディスカッション - ページ 29

 
Andrey Voytenko:

エラー1001をお持ちの皆さんにお尋ねします。

このスクリプトを実行し、その結果を Experts タブの行に貼り付けてください。

2020.06.05 18:06:36.033 WebRequest_Test_Script (EURUSD,H4) Build=2470 WebRequest=1001 GetLastError=5203 strData=

オペレーティング・システムの説明

Windows 7 7601 SP1

これはこの問題を解決するのに役立ちます。

まず最初に、アンドレイ、返信ありがとう。

これは私のスクリプト "t0.mql5 "の出力です:

2020.06.07 09:27:29.537 t0 (EURUSD,H1)  Build=2475 WebRequest=1001 GetLastError=5203 strData=


  • OS:
Windows 10 Pro 64 bit
command line "ver" command returns:Microsoft Windows [バージョン 10.0.18362.778]
  • メタトレーダー5、ビルド2475
  • と表示され、"GetLastError=5203" はHTTP リクエストが失敗した ことを意味します:ファイアウォールソフトはインストールしていません。
  • 1)BotFatherのトークン、2)ToolsOptions "Allowweb request"と関連するアドレス。3) 「VPN」サービスも使ってみたが、何も変わらなかった。4) Windowsファイアウォールをオフにした。
Documentation on MQL5: Network Functions / WebRequest
Documentation on MQL5: Network Functions / WebRequest
  • www.mql5.com
To use the WebRequest() function, add the addresses of the required servers in the list of allowed URLs in the "Expert Advisors" tab of the "Options" window. Server port is automatically selected on the basis of the specified protocol - 80 for "http://" and 443 for "https://". The WebRequest() function is synchronous, which means its breaks the...
 

コマンドプロンプトでこのリクエストを 実行し、結果をここに貼り付けてください。cURLをお持ちでない方はこちらからインストールしてくださいhttps://curl.haxx.se/windows/

curl -X POST https://api.telegram.org/bot177791741:AAEcSxsNEu8625Y2I4KAw_H7yGev9tl8uJg/getMe

aboozar sobboohi
aboozar sobboohi
  • www.mql5.com
Trader's profile
 
Andrey Voytenko:

コマンドプロンプトでこのリクエストを 実行し、結果をここに貼り付けてください。cURLをお持ちでない方はこちらからインストールしてください https://curl.haxx.se/windows/

curl -X POST https://api.telegram.org/bot177791741:AAEcSxsNEu8625Y2I4KAw_H7yGev9tl8uJg/getMe

Setup.exe "がありませんでした。あなたのトークンと私のトークンの両方を解凍して実行しました!

C:\t_SM\Telegram_mql5\curl-7.70.0_1-win64-mingw\curl-7.70.0-win64-mingw\bin>curl -X POST https://api.telegram.org/bot177791741:AAEcSxsNEu8625Y2I4KAw_H7yGev9tl8uJg/getMe
curl: (7) Failed to connect to api.telegram.org port 443: Connection refused

C:\t_SM\Telegram_mql5\curl-7.70.0_1-win64-mingw\curl-7.70.0-win64-mingw\bin>curl -X POST https://api.telegram.org/bot996256588:AAH2yUhFSjexpOUxxj2ZLOmRQXXItAF-B_4/getMe
curl: (7) Failed to connect to api.telegram.org port 443: Connection refused

解決済み "エラー:Unknown error 1001" =============> 私のISPの問題

今、私はcURLとWebrequestテスターからこの出力を持っています:

C:\t_SM\Telegram_mql5\curl-7.70.0_1-win64-mingw\curl-7.70.0-win64-mingw\bin>curl -X POST https://api.telegram.org/bot996256588:AAH2yUhFSjexpOUxxj2ZLOmRQXXItAF-B_4/getMe
{"ok":true,"result":{"id":996256588,"is_bot":true,"first_name":"Signal1","username":"Signal1bot","can_join_groups":true,"can_read_all_group_messages":false,"supports_inline_queries":false}}

"WebRequest_Test_Script.mq5" exexcution result on 'Experts' Tab of Toolbox:
2020.06.07 11:32:23.084 t0 (EURUSD,H1)  Build=2485 WebRequest=200 GetLastError=0 strData={"ok":true,"result":{"id":996256588,"is_bot":true,"first_name":"Signal1","username":"Signal1bot","can_join_groups":true,"can_read_all_group_messages":false,"supports_inline_queries":false}}

Andrey あなたのおかげで見つけることができました。

 
Andrey Voytenko:

エラー1001をお持ちの皆さんにお尋ねします。

このスクリプトを実行し、その結果を Experts タブの行に貼り付けてください。

2020.06.05 18:06:36.033 WebRequest_Test_Script (EURUSD,H4) Build=2470 WebRequest=1001 GetLastError=5203 strData=

オペレーティング・システムの説明

Windows 7 7601 SP1

これはこの問題を解決するのに役立ちます。

私はすでに2つのシステムであなたのスクリプトをテストしています

1つ目はwindows 7 7601 SP1で、あなたのエラーのようなエラーが実行されます
2つ目はwindows 10 pro 64 bit build 18363で、エラーなしでうまく実行されています。


 

GedThey MaThey

Windows 7 7601 SP1 のコマンドプロンプトでこのリクエストを実行し、結果をここに貼り付けてください。cURLをお持ちでない場合は、こちらからインストールしてくださいhttps://curl.haxx.se/windows/

curl -X POST https://api.telegram.org/bot177791741:AAEcSxsNEu8625Y2I4KAw_H7yGev9tl8uJg/getMe

curl for Windows
  • curl.haxx.se
These are the latest and most up to date official curl binary builds for Microsoft Windows. curl version : 7.70.0 Build : 7.70.0_1 Date : 2020-04-29 Changes : 7.70.0 changelog Packages curl for 64 bit Size: 3.2 MB sha256: c9ea2abc80b78e65f9eebe155272c7f27a80a264fe926a398aa5b48d4f5b4e0e curl for 32 bit Size: 3.0 MB sha256...
 
Andrey Voytenko:

ゲド戦記

Windows 7 7601 SP1 のコマンドプロンプトでこのリクエストを実行し、結果をここに貼り付けてください。cURLをお持ちでない場合は、こちらからインストールしてくださいhttps://curl.haxx.se/windows/

curl -X POST https://api.telegram.org/bot177791741:AAEcSxsNEu8625Y2I4KAw_H7yGev9tl8uJg/getMe

私はWindows 7からの結果を持っている

ファイル:
 
GedThey MaThey:

ウィンドウズ7での結果です。

有用なテスト結果 です。ありがとう。

 
Andrey Voytenko:

有益なテスト結果 だ。ありがとう。

ようこそ

 
Andrey Voytenko:

エラー1001をお持ちの皆さんにお尋ねします。

このスクリプトを実行し、その結果を Experts タブの行に貼り付けてください。

2020.06.05 18:06:36.033 WebRequest_Test_Script (EURUSD,H4) Build=2470 WebRequest=1001 GetLastError=5203 strData=

オペレーティング・システムの説明

Windows 7 7601 SP1

これはこの問題を解決するのに役立ちます。

追加テスト, 私は私のWindows 7 7601 sp1でmt4でテストしています 同じエラー

ファイル:
 

ラシード・ウマロフ 別のテストの結果だ。