English 中文(简体)
How would I strip an & symbol out of an ESRI dropdown before any of its default control logic is run?
原标题:

I have an ESRI dropdown control inside of an ESRI toolbar. One of the items in the dropdown needs to have an & symbol in it. As it turns out ESRI stuff builds its callback strings as & delimited strings, so when an item is selected the parent toolbar immediately builds and handles the callback string. At one point it splits strings based on the & crashing the app.

In effect, having an ampersand in an esri dropdown causes nasty stuff to happen when you select the item.

What I need to do is find out how I can hop in before the callback stuff starts happening and strip that & out. I was thinking that perhaps I d have to create a custom esri toolbar control, but I m not sure and that d be pretty undesirable.

Any ideas?

最佳回答

Welp. I went with a different approach if anyone is curious...

The callbacks are built off the dropdown item value whereas dropdown item names are what is displayed to the user. So, I set the name to be the one with the ampersand and the value to be the one without.

This requires some special checks at a couple of points, but overall the hack isn t too intrusive.

问题回答

暂无回答




相关问题
Script or automate feature class creation in ESRI/ArcSDE

I m looking for info on how to write SQL scripts to automate the creation of a versioned feature class in ArcSDE I want to be able to automate the process itself as well as put the scripts under ...

Esri mapobects in Delphi 2010

Has anyone installed ESRI mapobjects activeX controls in Delphi 2010? I get a conflict on tTable as a component name.

Alter map layer symbology dynamically (ArcGIS Server)

What is the preferred method of altering a layer s symbology dynamically? My web app consumes a map service via the REST API, but I don t mind using the SOAP API or ArcObjects (.NET).

热门标签