Hi there,

This is probably a query that has been asked multiple times, however, I'm new to vba and recroding macros, and honselty, I do not have time to learn the related codes, coding, etc. I tried recording a macro that will create a scatter graph (with smooth lines) and added axis titles to them.

However, each time I try to run this macro, it pops up with an error stating: Run-time error '424', Object Required. After this, it asks me debug, which I do by clicking the debug button.

The graph appears, the x-axis is fine, however, the y-axis does not.

It seems this line is the problem:

ActiveChart.Axes(xlValue, xlPrimary).AxisTitle.Text = "Force (N)"

I do not know what is the problem. This is not the first time I am having this issue. I do not understand why this problem occurs when I am recording the macro?

Here is the whole code because I am a complete novice, hence why I'm using the recording function.

Any help would be greatly appreciated!! I have been struggling with this for a while, and no idea how to tackle this

Please Login or Register  to view this content.