subscript out of range

  1. K

    Subscript out of range

    Good morning! I have a "Subscript out of range" issue. Background: working in Excel 2007 with an SAP BPC Add-In (BPC was formerly known as OutlookSoft). I know very little about VBA. We have a file (call it file #1) that contains the following VBA: Function AFTER_SEND(Argument As String)...
  2. 9tanstaafl9

    Can I assign a sheetname to a variable?

    How would I assign an unknown sheetname to a variable so that I can go back to the worksheet again in my macro when I don't know what the name of the sheet will be (the sheet is being added during the macro?) I was trying to do someting like this, but I keep getting a Runtime Error 9 subscript...
  3. S

    Code referencing another workbook - error

    I have the following code in my workbook. I want it to take the values of cells in the current workbook and scroll through another workbook to see if the value is present in there, and then perform a function if it is - else do nothing. The line preceeded with a lot of ***** is the line...
  4. I

    Cant delete all (except one) sheets

    Hello Forum! I would like to delete all except one sheets in the workbook by pressing onto a button. So I wrote the folllowing code (its obviously only a part) Application.DisplayAlerts = False For Each Worksheet In Worksheets If (Worksheet.Name <> "Instructions") Then...
  5. J

    Problem populating listbox from range (Subscript out of range error)

    Hi, On the change of a combobox that lists all worksheets within the current workbook, I am trying to dynamically populate a list box on the same form, from data contained in the 1st row of the chosen worksheet. I am receiving a "subsript out of range" error on the .AddItem MyList(i)...
  6. P

    VBA runtime error 9

    I'm struggling to explain an error message I'm getting when I step through some code I've written. The code below gets a 'sub script out of range' error and I'm not sure why... For i = 1 To 16 Workbooks(dataArray(16) &...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top