We value your feedback.
Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!
Function CheckSolver() As Boolean 'Found solution to Solver issue online in Google search ' Peltier Technical Services, Inc., Copyright © 2007. All rights reserved. ' Returns True if Solver can be used, False if not. Dim bSolverInstalled As Boolean ' Assume true unless otherwise CheckSolver = True On Error Resume Next ' check whether Solver is installed bSolverInstalled = Application.AddIns("Solver Add-In").Installed Err.Clear If bSolverInstalled Then ' uninstall temporarily Application.AddIns("Solver Add-In").Installed = False ' check whether Solver is installed (should be false) bSolverInstalled = Application.AddIns("Solver Add-In").Installed End If If Not bSolverInstalled Then ' (re)install Solver, should be gone Application.AddIns("Solver Add-In").Installed = True ' check whether Solver is installed (should be true) bSolverInstalled = Application.AddIns("Solver Add-In").Installed End If If Not bSolverInstalled Then MsgBox "Solver was not found. This workbook will not work properly Solver addin is installed.", vbCritical CheckSolver = False End If If CheckSolver Then Dim solverProg As String On Error Resume Next ' turn on error handler 'Next line needed to deal/remove unexspected memory error. Application.Run "Solver.xla!Solver.Solver2.Auto_open" 'Application.Run "Solver.xla!Auto_Open" If Err.Number <> 0 Then 'solver.xla error occurred, use solver.xlam instead solverProg = "Solver.xlam" Application.Run solverProg + "!Solver.Solver2.Auto_open" 'MsgBox "File found and will used Solver.xlam " If Err.Number <> 0 Then MsgBox ("Solver.xla or Solver.xlam not found. Exiting.") ' or whatever message you want to use 'Exit Sub End If Else 'solver.xla ran successfully solverProg = "Solver.xla" 'MsgBox "File found and will use Solver.xla " End If End If On Error GoTo 0 End Function
|Macro jumps into function section of another macro for no apparent reason||6||34|
|Extracting a text date string into another column and having it convert to a 'real' date format in Excel||5||24|
|Modify Array formula - Reduce Calculation Time||4||28|
|Excel 2016 - How to prevent inserted column from inheriting attributes of column to the left||8||12|