laptop and a wrench

不具合

Toolbar::CurrentTool returns an empty string when in callback request/response.

最後に公開された状態: August 25, 2014 No Product Found
不具合 ID 番号 NIM006759
送信されましたFebruary 12, 2007
最終更新日June 5, 2024
適用対象No Product Found
見つかったバージョン9.2
プログラム言語C#
ステータスWill Not Be Addressed

参考情報

No Public Explanation

対処法

When click any tool in toolbar, execute a Javascript to send a callback request to the server with the current tool name. And save the string in a session variable. In the future the current tool name could be retrieved from the session variable. Here is the code:Client side Javascript: function currenttool() { toolbar = Toolbars["Toolbar1"]; var f = document.form1; var mod = f.elements[toolbar.currentToolField].value; return mod; } function manuallyCallbackrequest() { var message = currenttool(); var context = null; <%=sCallbackInvotion%> }Server side code:public partial class _Default : System.Web.UI.Page, ICallbackEventHandler{ public string sCallbackInvotion; protected void Page_Load(object sender, EventArgs e) { sCallbackInvotion = Page.ClientScript.GetCallbackEventReference(this, "message", "processCallbackResult", "context", "postBackError", true); } protected void Map1_MapClick(object sender, ESRI.ArcGIS.ADF.Web.UI.WebControls.PointEventArgs args) { if (Session["currentToolName"] != null) { System.Diagnostics.Debug.WriteLine(Session["currentToolName"].ToString()); } } #region ICallbackEventHandler Members public string GetCallbackResult() { return null; } public void RaiseCallbackEvent(string eventArgument) { Session.Add("currentToolName", eventArgument); } #endregion}

再現の手順

不具合 ID: NIM006759

ソフトウェア:

  • No Product Found

バグのステータスが変更されたときに通知を受け取る

Esri Support アプリのダウンロード

このトピックについてさらに調べる

ArcGIS エキスパートのサポートを受ける

テクニカル サポートへのお問い合わせ

Esri Support アプリのダウンロード

ダウンロード オプションに移動