Subscript out of range vba error 9 excel, but it works on other laptops

AntuanKriaki

New Member
Joined
Jan 22, 2024
Messages
7
Office Version
  1. 365
  2. 2021
Platform
  1. Windows
Hello Everyone, this is my first post in this community, I have this very weird problem regarding on the Macros files with excel, basically, there is a file using Macros working on my laptop, but I can't make it work on other laptops, those other laptops have the same office version, and even the same systems and config on each one of them, when I try to add or edit anything it gives this error: (subscript out of range, error 9), I will include a photo who the VBA looks in each laptop where this file doesn't work, if you have anything to add please let me know, because I already searched for this too many times now,

Thanks,
MicrosoftTeams-image.png
 

Excel Facts

Using Function Arguments with nested formulas
If writing INDEX in Func. Arguments, type MATCH(. Use the mouse to click inside MATCH in the formula bar. Dialog switches to MATCH.
I recall from years ago that "Subscript out of range" error can also be displayed when a specified sheet does not exist.
 
Upvote 0
I recall from years ago that "Subscript out of range" error can also be displayed when a specified sheet does not exist.
but as I mentioned, this file works on other computer with the same config and same office version
 
Upvote 0
Same problem here.

Again opening files
Same problem, with a solution
 
Upvote 0
Which line is actually causing the error?
 
Upvote 0
Just one other comment. The green test below will always be true so the yellow lines will always be executed.

1706007280658.png


I suspect you really meant 'And' where you have 'Or' in the green line
 
Upvote 0
Just one other comment. The green test below will always be true so the yellow lines will always be executed.

View attachment 105553

I suspect you really meant 'And' where you have 'Or' in the green line
But why it shows question marks on the sheet name, and on a working laptop it shows the right name in other language?
 
Upvote 0
But why it shows question marks on the sheet name, and on a working laptop it shows the right name in other language?
I don't know, but presumably because of the different language/regional settings on each machine.

Your question though is unrelated to my comment about the vba code.
 
Upvote 0
Solution
I understand that, but your comment is also nothing to do with the problem that its not working on other laptops, when I press Debug, it shows that all the code is wrong, because it doesn't recognize the language, it basically shows questions marks and so on, and that only laptop that it works, the language shows ok
 
Upvote 0
but your comment is also nothing to do with the problem that its not working on other laptops,
True. My point was simply about some unusual logic in the code that I thought you might be interested in knowing about.

You did say ..
if you have anything to add please let me know,
.. so I let you know.
 
Upvote 0

Forum statistics

Threads
1,224,814
Messages
6,181,123
Members
453,021
Latest member
Justyna P

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