- ChartID
- Mode
- Foreground
- Shift
- ShiftSize
- AutoScroll
- Scale
- ScaleFix
- ScaleFix_11
- FixedMax
- FixedMin
- PointsPerBar
- ScalePPB
- ShowOHLC
- ShowLineBid
- ShowLineAsk
- ShowLastLine
- ShowPeriodSep
- ShowGrid
- ShowVolumes
- ShowObjectDescr
- ShowDateScale
- ShowPriceScale
- ColorBackground
- ColorForeground
- ColorGrid
- ColorBarUp
- ColorBarDown
- ColorCandleBull
- ColorCandleBear
- ColorChartLine
- ColorVolumes
- ColorLineBid
- ColorLineAsk
- ColorLineLast
- ColorStopLevels
- VisibleBars
- WindowsTotal
- WindowIsVisible
- WindowHandle
- FirstVisibleBar
- WidthInBars
- WidthInPixels
- HeightInPixels
- PriceMin
- PriceMax
- Attach
- FirstChart
- NextChart
- Open
- Detach
- Close
- BringToTop
- EventObjectCreate
- EventObjectDelete
- IndicatorAdd
- IndicatorDelete
- IndicatorsTotal
- IndicatorName
- Navigate
- Symbol
- Period
- Redraw
- GetInteger
- SetInteger
- GetDouble
- SetDouble
- GetString
- SetString
- SetSymbolPeriod
- ApplyTemplate
- ScreenShot
- WindowOnDropped
- PriceOnDropped
- TimeOnDropped
- XOnDropped
- YOnDropped
- Save
- Load
- Type
IndicatorDelete
从指定的图表窗口删除指定名称的指标。
bool IndicatorDelete(
|
参数
sub_win
[输入] 图表子窗口的号码。0 代表图表的主窗口。
const name
[输入] 指标的简称, 即在 INDICATOR_SHORTNAME 属性里, 使用 IndicatorSetString() 函数设置的值。为获得指标的简称请使用 IndicatorName() 函数。
返回值
指标成功删除后返回 true。否则返回 false。为获得 出错信息 详情请使用 GetLastError() 函数。
注释
如果在同一图表子窗口里存在两个相同简称标识符的指标, 则第一个被删除。
如果图表中有其它指标基于此被删除的指标值, 则这些指标也一并删除。
请不要将指标简称与使用函数 iCustom() 和 IndicatorCreate() 创建指标时指定的文件名混淆。如果指标的简称没有明确设置, 则在编译期间用包含指标源代码的文件名来指定。
从图表中删除一个指标并不代表其计算部分也从临时内存里删除。释放指标句柄请使用 IndicatorRelease() 函数。
指标的简称应规范正确。它应该在 INDICATOR_SHORTNAME 属性里使用 IndicatorSetString() 函数来写入。建议指标简称应包含所有输入参数值, 因为从图表里用 IndicatorDelete() 函数删除指标时将以简称作为标识。
参阅
IndicatorAdd(), IndicatorsTotal(), IndicatorName(), iCustom(), IndicatorCreate(), IndicatorSetString()。