| Knowledgebase Home | Contact |
| I have Surfer 8 and 9 installed. How do I know which version my script will use? | |||||||||
If you have more than one version of Surfer installed, the script will use whichever version of Surfer was last opened. So you can open Surfer 8, close it, run the script and it will run in Surfer 8. Then open Surfer 9, close it, run the script and it will run in Surfer 9. You can also use the Shell command in the script to specifically state which version of Surfer to open. For example: Sub Main 'Open Surfer 9 and use that instance to run the script Shell "c:\program files\golden software\Surfer 9\Surfer.exe" Wait 4 Dim SurferApp As Object Set SurferApp = GetObject(,"Surfer.Application") SurferApp.Visible = True Dim Plot As Object Set Plot = SurferApp.ActiveDocument 'Declares MapFrame as Object Dim MapFrame As Object 'Creates a contour map and assigns the map frame to the variable "MapFrame" Set MapFrame = Plot.Shapes.AddContourMap(GridFileName:=SurferApp.Path+"\Samples\demogrid.grd") End Sub |
| Visitor Comments |
| No visitor comments posted. Post a comment |
| Attachments |
| No attachments were found. |