View Full Version : Run-time error '9' Problem

11-22-2010, 01:49 PM
I'm linking a particular cell with a hyperlink that is date specific, so when I change the date I'm looking up data for I would like to pull up the website to the particular day. Here is the code:

Private Sub Update_All_Savings()
Dim Hyperlink_Change As String

Application.Run ("OpenCalendar()") This is where the date is changed
Production_Day = Range("BZ1").Value
Hyperlink_Change = Range("CC1").Value Cell CC1 contains the concatenation equation that comes up with the date specific website address
Application.ScreenUpdating = False
Application.DisplayAlerts = False
Selection.Hyperlinks(1).Address = Hyperlink_Change
'Hyperlinks (1) is the previous dates hypelink

When stepping through the macro here I get the Run-time error '9' Subscript out of Range

Any clues to my mistake?:dunno

11-22-2010, 02:09 PM
Where do you get the error?