Change the symbol properties in post map via Surfer automation

The PostLayer Object in the Help outlines all of the available commands in the Properties and Methods tables. Click on Symbol and you'll see that Symbol returns a MarkerFormat object. That means that all commands for the MarkerFormat object also apply to the Symbol.


Click on the MarkerFormat object and you will see the options for the color and index (shape within a symbol set) and all other options.


For example:

Set MapFrame = Plot.Shapes.AddPostMap(SurferApp.Path+"\samples\demogrid.dat", LabCol:=3)
Dim PostLayer As Object
Set PostLayer = MapFrame.Overlays(1)
PostLayer.Symbol.Set = "GSI Default Symbols"
PostLayer.Symbol.Index= 6
PostLayer.Symbol.FillColorRGBA.Color = srfColorRed
PostLayer.Symbol.LineColorRGBA.Color = srfColorCyan
PostLayer.SetSymbolScaling(Method:=srfPostLinear, SymbolHeight1:=0.1, SymbolHeight2:=0.5, ScaleValue1:=1, ScaleValue2:=100, HeightCol:=3)
PostLayer.SymAngle = 315
PostLayer.SymFrequency = 2


See also the attached script, PostMap.bas, which can also be found in the \Samples\Scripts\ folder in the Surfer installation directory.


Updated November 2021

Was this article helpful?
1 out of 2 found this helpful



Please sign in to leave a comment.