5.64 FAQ-926 Can I control which window displays in File Explorer Icon Views and Preview pane?

Last Update: 3/5/2020

When you save an OPJU file with Origin 2018b or later, one project window is used for the Windows File Explorer icon (in File Explorer, don't select any file, right-click and choose one of the icon view, e.g. Extra large icons). Additionally, the same window will show at the top of the list of previewed windows when the File Explorer Preview Pane is enabled (ALT + P).

FAQ-926 Windows File Explorer Views.png

In the simplest cases, the active graph window is used to create the project file icon. In more complex project files or in situations where you require a certain window type to serve as the project icon, you can exert some control by setting the value of the "@ System Variable" @SPM, with respect to the following window priority rankings:

Matrix = 1
Worksheet = 2,
HolderImage = 3 //book with MatrixSheet in Image View
MatImage = 4  //matrix in Image View
HolderGraph = 5 
GraphNotOpen = 6 //in another folder, hidden or iconized
Graph = 7

... where "Holder" refers to a Graph or Matrix added to a Workbook as a Sheet, and if a Matrix, View must be Image Mode (View: Image Mode).

The variable @SPM determines if a given window type will be elevated to "Must Use if Active". By default, @SPM = 3 but can be changed in the Script Window (Window: Script Window) to any of the above values. The value of @SPM is stored in the Windows registry and will persist across Origin sessions until it is again changed.

As an example, if you set @SPM=5, then only graphs will be used, either standalone graph windows or "HolderGraphs" (graphs added as sheets to workbooks). If the active window is not a graph, another visible graph window (not iconized) will be used, if available. If there are multiple such graph windows in the current folder, the one that was last active will be used.

If you are concerned about the effect of preview on file size, you can prevent saving of Project Explorer previews into files using System Variable @PESS.

Keywords:active graph, embedded graph, graph sheet, matrixsheet, matrix sheet, Project Explorer, previews