Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Hi, I recently copied code out of one VBA project and pasted it into a new project. The code still works fine in the original project, but in the new project I get the Compile Error:Can't find project or library. VBA help says this is due to a missing reference and direct me to "Display the References dialog box", but I can't locate this dialog box anywhere. Here is my code and the editor highlights "msg =" in the code. Any help would be greatly appreciated. Sub DeleteBlankLastRow_CheckIfBlank() Dim Response As Integer Dim rngEntryBottomRow As Range On Error GoTo ws_exit Application.EnableEvents = False Application.ScreenUpdating = False ActiveSheet.Unprotect ("geekk") Set rngEntryBottomRow = Range("Below_Entry_Bottom_Row").Offset(-1) 'if last detail row is blank, delete one detail row and If not empty ' then msg box to explain error and exit sub. If Application.WorksheetFunction.CountA(rngEntryBotto mRow) 5 Then Msg = MsgBox("You are attempting to Delete a Row that contains User Input. Delete Row Failed", vbOKOnly + vbCritical, "Can Not Delete Row with Information") If Response = 1 Or 2 Then Exit Sub End If If Application.WorksheetFunction.CountA(rngEntryBotto mRow) = 5 Then With rngEntryBottomRow 'rngI ..EntireRow.Delete End With End If ActiveSheet.Protect ("geekk"), DrawingObjects:=True, Contents:=True, Scenarios:=True Application.ScreenUpdating = True ws_exit: Application.EnableEvents = True End Sub -- Casey ------------------------------------------------------------------------ Casey's Profile: http://www.excelforum.com/member.php...fo&userid=4545 View this thread: http://www.excelforum.com/showthread...hreadid=395380 |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Compile error: Can't find project or library | New Users to Excel | |||
Can't Find Project or Library Error | Excel Discussion (Misc queries) | |||
can't find project or library - error | New Users to Excel | |||
Comple Error Cannot Find Project or Library | Excel Programming | |||
Compile error: Can't find project or library | Excel Programming |