Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
サーバーが応答しない、またはタイムアウトしたエラーをキャッチしたい。PageMethodsasp.netWebアプリケーションのjavascriptからサーバーサイドの関数を呼び出すために使用していました。サーバーが応答しない場合があるので、aspxファイルにあるjavascriptからPageMethodsを呼び出したときに、サーバーが応答しないことを処理したいと思います。
PageMethods
よろしくお願いします。
簡単なトライキャッチで問題は解決すると思います
try { PageMethods.MyMethod(); } catch(exception){ //error occured } finally { //some tidying up }
javascripttrycatchリファレンス