C
cubbybear3
I have the following code from Excel 2003 and can not seem
to get it to work in Excel 2007.
I get the error "Can't find project or library" on "CurDir".
Any clues as to what I am doing wrong or what it got changed to?
' save the Drive letter and path
strTmp =
ActiveSheet.Evaluate(ActiveWorkbook.Names("drive.path").RefersTo)(1)
If (strTmp <> Application.Workbook.Path) Then
ActiveWorkbook.Names.Add Name:="drive.path", RefersToR1C1:= _
"={" & Chr(34) & Application.Workbook.Path & Chr(34) & "}"
End If
to get it to work in Excel 2007.
I get the error "Can't find project or library" on "CurDir".
Any clues as to what I am doing wrong or what it got changed to?
' save the Drive letter and path
strTmp =
ActiveSheet.Evaluate(ActiveWorkbook.Names("drive.path").RefersTo)(1)
If (strTmp <> Application.Workbook.Path) Then
ActiveWorkbook.Names.Add Name:="drive.path", RefersToR1C1:= _
"={" & Chr(34) & Application.Workbook.Path & Chr(34) & "}"
End If