This is the spreadsheet that manages access to the COM server and to the ClaDb composite database used for calculations. This is the first spreadsheet you should go to in order to start the application.
The spreadsheet contains several buttons, and information on the entities available in the current database appears in the cells: lists of materials, laminates and loads. Each entity in the current database is characterized by:
an integer ID,
a String ID,
an Excel ID.
The integer and String IDs correspond to the CLA identifier of the entity. The Excel ID is a String representation of this identifier that allows the entities to be referenced from the other spreadsheets. The spreadsheet defines several buttons:
The ComboBox button is used to select the type of file from which a database is to be read, or from which database entities are to be imported. This file format must be correctly set for the file read/import operations to work properly. Four file formats are supported: “ESAComp” EDF file, FeResPost neutral data file (NDF), Nastran BDF bulk data file, and Samcef DAT bank file.
The “Read Data File” button is used to read a new ClaDb database. All the entities stored in the current database are first deleted. Note that the ComboBox button must have been set correctly before reading entities.
The “Import Data File” button performs the same operation, but the entities that have been read are added to the current database. (They also replace any existing entities with the same ID.)
Three command buttons perform the same operation as the “Import Data File” button, except that each time, only one type of entity is read: the “Import Laminates”, “Import Materials” and “Import Loads” buttons.
The button “Save FeResPost NDF file” is used to save the composite database to a neutral data file. (Only neutral data files can be saved by FeResPost.)
The button “Show/Hide FeResPost” is used to show or hide the FeResPost server window. Note that the FeResPost server continues to run even when it is hidden.
The button “Close FeResPost” actually closes the FeResPost server. When this is done, the composite database is closed too, but its content is not saved! (So be careful with this button.)
The button “Delete Selected Entities” is used to remove entities from the composite database. To use this button, you must first select a range among the entities that appear below, then press the button. To select a range, at least the three columns corresponding to the entities you want to remove must be selected.
The two buttons “SaveDbToNeutralLines” and “RetrieveDbFromNeutralLines” are used to store the current database in the hidden “NeutralLines” spreadsheet. This allows you to recover the database you were working with the last time you used the workbook, without reading an NDF file. (Of course, you have to save the Excel workbook before quitting.)
Several macros are defined in the spreadsheet. Most of these macros perform the operations triggered by the buttons. You can access the macros through the VBA editor. At the beginning of the VBA program lines, several variables are defined:
Dim frpApp As Variant Dim db As Variant Dim maxEntitiesNbr As Long Const maxPliesNbr As Long = 100 Const appName As String = "FeResPost_3_4_0.Application" Const logFileName As String = "FeResPost_LaminateAnalysis.log"
frpApp is the variable that holds a reference to the FeResPost COM server. db holds the ClaDb composite database in which all composite entities are stored. Only one ClaDb database can be opened in the workbook. The variable “appName” is a constant that corresponds to the name of the server. You will have to change this variable when you change the version of FeResPost.
The logFileName variable is used to redirect FeResPost output messages. This is necessary because, within Excel, FeResPost is not run in console mode. In practice, this redirection is implemented as follows in the “getApplication” method:
fullLogName = ActiveWorkbook.Path + "\" + logFileName frpApp.openMsgOutputFile fullLogName, "w+" frpApp.writeAboutInformation