The QueryWithinRange method queries boundary objects within a specified distance from a single selected boundary. The distance is defined in the current document's surface distance units.
Syntax
object.QueryWithinRange( Action, RangeRadius, Area, Curve, Point, Rectangle, RoundedRect, Square, Ellipse, Circle, PartiallyInRegion, AllVisibleLayers, FillFGColor, FillBGColor, FillTransparent, FillPattern, LineColor, LineStyle, LineWidth, SymbolSet, SymbolIndex, SymbolSize, SymbolFillColor, SymbolLineColor, FillPatternScale, FillPatternCoverMode )
Parameter |
Type |
Description |
Action |
optional; action to take with query results |
|
RangeRadius |
Double |
optional; distance from selected object in surface distance units |
Area |
Boolean |
optional; true to return areas for query results |
Curve |
Boolean |
optional; true to return curves for query results |
Point |
Boolean |
optional; true to return points for query results |
Rectangle |
Boolean |
optional; true to return rectangles for query results |
RoundedRect |
Boolean |
optional; true to return rounded rectangles for query results |
Square |
Boolean |
optional; true to return squares for query results |
Ellipse |
Boolean |
optional; true to return ellipses for query results |
Circle |
Boolean |
optional; true to return circles for query results |
PartiallyInRegion |
Boolean |
optional; true to include objects that partially touch zones |
AllVisibleLayers |
Boolean |
optional; true to use all visible layers |
FillFGColor |
optional; foreground fill color if the Action is mvQueryVerbApplyProperty, see remarks |
|
FillBGColor |
optional; background fill color if the Action is mvQueryVerbApplyProperty, see remarks |
|
FillTransparent |
Boolean |
optional; if the Action is mvQueryVerbApplyProperty, true to make background fill transparent, FillPattern must be stock or vector |
FillPattern |
String |
optional; fill pattern if the Action is mvQueryVerbApplyProperty |
LineColor |
optional; line color if the Action is mvQueryVerbApplyProperty |
|
LineStyle |
String |
optional; line style if the Action is mvQueryVerbApplyProperty |
LineWidth |
Double |
optional; line width if the Action is mvQueryVerbApplyProperty |
SymbolSet |
String |
optional; symbol set if the Action is mvQueryVerbApplyProperty |
SymbolIndex |
Integer |
optional; symbol number if the Action is mvQueryVerbApplyProperty, see remarks |
SymbolSize |
Double |
optional; symbol size if the Action is mvQueryVerbApplyProperty |
SymbolFillColor |
optional; symbol color if the Action is mvQueryVerbApplyProperty |
|
SymbolLineColor |
optional; symbol outline color if the Action is mvQueryVerbApplyProperty |
|
FillPatternScale |
Double |
optional; vector pattern scale if the Action is mvQueryVerbApplyProperty |
FillPatternCoverMode |
optional; picture pattern cover or tile if the Action is mvQueryVerbApplyProperty, default is mvFillCoverModeTile |
Remarks
Use the enumeration [ mvColorRed], RGB value [RGB(255,0,0)], or number [255] to set a color.
The symbol number can be found in the Symbol Properties dialog. Add 32 if you are using TrueType fonts such as GSI Default Symbols.
An object must be selected to use the QueryWithinRange method.
Example
'QueryWithinRange
'Create a hatch map and assign it to the variable "HatchMap"
Set HatchMap = Plot.CreateHatchMap(BoundaryFileName:=mvApp.ModuleFolder + "\Samples\CO2010.gsb", _
DataFileName:=mvApp.ModuleFolder + "\Samples\CO2010.dat", _
PIDCol:=1, VarCol:=7)
'Select the boundary with PID "08041"
HatchMap.Parent.Shapes.SelectByPID(PIDName:="08041")
'Show all boundaries within 1 lat/lon unit away from the selected boundary
Plot.QueryWithinRange(Action:=mvQueryVerbShow, RangeRadius:=1)
Used by: PlotDocument