how to get the Y Axis to cross at "Today's Date" i

cathyo

New Member
Joined
Jan 19, 2003
Messages
48
I'm sorry - I'm under a time constraint and didn't spend much time searching for an answer...thus, I could use help as soon as possible.

I'm creating a chart where the X axis are dates, everyday -- past 3 weeks months as well as the next 3 weeks. The data plotted to the left of "today" is actual data, whereas the data plotted to the right is estimated data.

I create a vertical line on the graph to indicate where "today" is (double click on X axis, format axis window appears, go to scale index and change the date in the "Value (Y) axis crosses at"

I added a button with a macro assigned to it that will refresh the data and update the chart -- I recorded a macro that changes the date but the code shows "09/28/2006" in the code and I'd like to change the code so it's enters today's date. Can anyone help? Thank You!
 

Excel Facts

Pivot Table Drill Down
Double-click any number in a pivot table to create a new report showing all detail rows that make up that number
Code:
    With ActiveChart.Axes(xlCategory)
        .CrossesAt = Now
    End With
 
Upvote 0

Forum statistics

Threads
1,215,045
Messages
6,122,836
Members
449,096
Latest member
Erald

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