MGM Workbooks > MGM Workbook

MGM Workbook


The MGM workbook is the control centre for the MGM model and user interface. It is the workbook from which the other workbooks (CropPlans, Stands, and Records) are controlled. It consists of the MGM Toolbar and a set of worksheets that are used to develop Crop Plans and make growth projections based on the crop plan or crop plans.

The typical user will initiate work with MGM by opening an existing copy of the MGM workbook from within an MGM working directory. In most situations it will be sufficient to have only one copy of the MGM directory.Opening New MGM workbooks and MGM directories After successful installation and testing of workbooks, there are two methods for creating working copies of workbooks where you can begin to do your own projection applications.

Method 1.
The entire MGM directory may be copied and renamed as desired for developing and completing growth projections. It is strongly recommended that you copy the entire MGM directory to a location that is convenient for use when developing and doing growth simulations. This can be on any drive or directory on the same machine. Copies of the MGM directory can be copied, moved, or renamed as needed. This preserves the original MGM directory and workbook files and also allows you to work in the location where you keep other working files and documents. This method maintains access to the local copy of the MGM Help web.

Method 2.

This method is likely to be of interest only to advanced users.

A New MGM workbook may be started the Excel|New... menu using the MGM template. This also preserves the original installation copy of the workbook and related files.

The new workbook may not be created in the desired directory so the workbook will likely not find CropPlans, Records, or stands workbooks.

Projections may be made from any directory, but actions requiring the subordinate workbooks will fail (with messages to the user) unless the new book is saved into a directory where those workbooks are found. The user is warned about this and should immediately save the new workbook with an appropriate name in a directory that contains the subordinate workbooks (Crop Plans, Stands, and Records). Starting a New MGM workbook makes it easy to have multiple copies of the MGM workbook in the same working directory.

Starting a New MGM workbook in this method may cause the local copy of the MGM Help web to be unavailable.Opening multiple copies of the MGM workbook Most users will not need more than one copy of the MGM workbook open at any time. If you don't need to use more than one workbook, you can stop reading this section.

Advanced users may sometimes want to open multiple copies of the MGM workbook for comparison or editing. However, care must be exercised in doing this.

There can be multiple instances of Excel which can each open an MGM workbook and operate entirely independently of the other instances of Excel. In this situation, remember that working with subordinate workbooks (Crop Plans, Stands, or Records) may cause conflicts unless the MGM settings point to different workbooks. See MGM Tools Menu for more information on setting MGM workbook names.

If multiple workbooks are open in the same instance of Excel, the MGM Toolbar works as it should when switching between workbooks and closing them. Only one CP (workbook) Can be projected at a time. You cannot switch between workbooks during a projection.

Excel Copy/Paste actions between workbooks should work without difficulty provided the user isn't attempting to paste formulas but only values. For most applications I would think copy/paste would be most likely in constructing or modifying CP and these don't contain formulas. Still there should be warnings in the documentation.MGM workbook structure and worksheets Development of crop plans simulation of stand growth is completed in the Crop Plans worksheet. Example crop plans are included in the MGM Crop Plans workbook, and these allow the user to get a feeling for what a crop plan may look like before attempting to construct new plans. Results of the growth simulation are placed into the Record worksheet. The Stand worksheet shows the stand data at different times during the growth projection. It may also be used to edit stand data. Other sheets portray the results of growth projection in both graphical (Charts, MyCharts, and Graphs) and tabular (Record, Stand and Stand Table, Yields) form.

Worksheets are generally 'unprotected' so the user must exercise some care in modifying cells values. It is particularly important that cell formulas not be modified. Additionally, the workbook 'structure' is protected. Worksheets may not be added, deleted, or renamed. A user worksheet is provided where the user may do computations or paste results.MGM Toolbar and guidelines for working with the MGM workbook For most tasks used to construct and execute a growth projection, the MGM Toolbar should be used. The toolbar buttons and MGM Tools menu facilitate constructing and editing events in the Crop Plan as well as viewing and saving the results of growth simulations. Manual changes to individual cells in all worksheets should be avoided. Wherever possible use the MGM Toolbar menu and buttons.

Once a projection has been completed, users may use some Excel commands such as Copy and Paste to extract numeric data and charts for further work. To prevent problems with formula results, 'Paste Special Values Only' should be used for cells that have been copied from other worksheets in the MGM workbook. Charts may be copied and pasted directly since they are not linked to formula results. Since entire worksheets cannot be copied, use the 'Edit|Select All' menu item to copy the contents of a worksheet to the UserWorkArea or another Excel workbook.Actions on opening the workbook On startup, if the setting for the directory containing MGM files is incorrect, error messages may appear prompting the user to designate the location of MGM files (MGM Tools).

Unless altered by the user as he works and saves a "working" copy of the original workbook, the workbook opens in the .Crop Plan. worksheet and a dialog titled .MGM Notes. is displayed. This dialog provides a simple text edit box that can be used to place notes or reminders. A checkbox control specifies whether the MGM Notes dialog appears on startup; the MGM Tools menu can also be used to edit or alter the settings.

To prevent later loss, changes to the startup crop plan (the contents of the Crop Plans worksheet that appears when the MGM workbook is opened) must be saved BOTH in the MGM workbook (Excel File|Save) and in the Crop Plans workbook (MGM Toolbar menu item Save Crop Plan). This is necessary because the starting crop plan is usually only a temporary location for the crop plan. The primary copy should be saved in the Crop Plans workbook by clicking the Save button on the MGM Toolbar. If you want to preserve the changes and have them appear when the MGM workbook is opened, then the MGM workbook must also be saved using the Excel File|Save menu item. Understanding the contents of the worksheets. All worksheets except the Crop Plans worksheet are modified by executing all or part of the contents of the Crop Plans worksheet. These result worksheets include the Record, Yields, Charts, My Charts, Graphs, Stand, and Stand Table worksheets.

Modifications to the Crop Plans worksheet are preserved when the MGM workbook is saved and the crop plan may alsobe saved separately into the MGM Crop Plans workbook by clicking the Save button on the MGM Toolbar.

Restoring (opening) a new or existing Crop Plans worksheet from the MGM Crop Plans workbook by clicking on the Open button on the MGM Toolbar retains the contents of the Record worksheet but alters contents of other worksheets.

The tree list in the Stand worksheet is cleared and stand summary formulas show Excel "REF" errors. Formulas are updated (and the errors disappear) when the CP is executed. Other worksheets may also reflect missing data or may show residual values from previous executions. When this occurs, a message appears Run Date cell of the Stand worksheet indicating "INCOMPLETE" results.

Certain other actions will also alter the contents of the worksheets so that they no longer represent the results of the most recent crop plan execution.

  • Activating the ViewRecord dialog on the MGM Toolbar may modify the contents of the Record worksheet. If the Record worksheet is modified by importing a Record or changing the Record within the workbook, the link to the most recent execution is severed and the Run Date cell of the Stand worksheet indicates "INCOMPLETE". The Yields, Charts, My Charts, and Graphs worksheets are then updated (manually or automatically) to reflect the content of the Record worksheet.
  • Initializing the MGM workbook by clicking the “MGMTools|Initialize workbook” button) preserves the contents of all worksheets. This includes any modifications caused by use of the ViewRecord toolbar button. Again, the Stand worksheet Date Run cell should indicate "INCOMPLETE" if changes have been made using the ViewRecord dialog.
  • Opening the workbook (after it has been closed with or without saving it) also causes the workbook to be Initialized and has the same effect as the as pressing the Initialize button on the MGM toolbar.Behind the scenes A VBA interface provides the ability to run the MGM growth simulations and manage files. These components are not visible to users. Users must maintain the basic structure of the workbook and the various settings. If in doubt, "leave it alone".