PC Review


Reply
Thread Tools Rate Thread

auto update of conditional macro

 
 
@Homeonthecouch
Guest
Posts: n/a
 
      20th Mar 2007
Hi again,
I have just noticed that when I open the spreadsheet the cell with the
=today() command automatically updates but the macro that is dependant on
the answer does not update.
I have tried to use refresh F9 but that doesn't work. I can go into the cell
and hit enter and that then refreshes the colour assigned to the day.
Is there a way of doing this when the spreadsheet opens up? Or is that not
advisable?

Andrew



 
Reply With Quote
 
 
 
 
Dave Peterson
Guest
Posts: n/a
 
      20th Mar 2007
Are you using the worksheet_calculate event? That event recalced for me when I
opened a workbook with =today() in a cell (xl2003).

If you're not using that event, maybe you could call your macro from the
Workbook_Open event or the Auto_Open procedure?





"@Homeonthecouch" wrote:
>
> Hi again,
> I have just noticed that when I open the spreadsheet the cell with the
> =today() command automatically updates but the macro that is dependant on
> the answer does not update.
> I have tried to use refresh F9 but that doesn't work. I can go into the cell
> and hit enter and that then refreshes the colour assigned to the day.
> Is there a way of doing this when the spreadsheet opens up? Or is that not
> advisable?
>
> Andrew


--

Dave Peterson
 
Reply With Quote
 
@Homeonthecouch
Guest
Posts: n/a
 
      20th Mar 2007
Private Sub Worksheet_Change(ByVal Target As Range)

If Target.Cells.Count > 1 Then Exit Sub
If Intersect(Target, Range("L22:L23")) Is Nothing Then Exit Sub

With Target
Select Case Weekday(.Value)
Case Is = vbMonday: .Offset(-1, 0).Resize(2,
1).Interior.ColorIndex = 7
Case Is = vbTuesday: .Offset(-1, 0).Resize(2,
1).Interior.ColorIndex = 44
Case Is = vbWednesday: .Offset(-1, 0).Resize(2,
1).Interior.ColorIndex = 6
Case Is = vbThursday: .Offset(-1, 0).Resize(2,
1).Interior.ColorIndex = 4
Case Is = vbFriday: .Offset(-1, 0).Resize(2,
1).Interior.ColorIndex = 8
Case Is = vbSaturday: .Offset(-1, 0).Resize(2,
1).Interior.ColorIndex = 33
Case Is = vbSunday: .Offset(-1, 0).Resize(2,
1).Interior.ColorIndex = 18
End Select
End With

End Sub

So I would assume no?

I am totally inexperienced with VBA and have no real idea what I am doing, I
am learning the methods I find on the net and in these help groups.
Do I need to change the Worksheet_Change to Worksheet_Calculate?
The cell updates perfectly when the workbook is opened but the colour
remains the same as the last time the cell was updated when enter was hit.


--
Help and patience is as always appreciated
Thank You

Andrew


"Dave Peterson" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Are you using the worksheet_calculate event? That event recalced for me
> when I
> opened a workbook with =today() in a cell (xl2003).
>
> If you're not using that event, maybe you could call your macro from the
> Workbook_Open event or the Auto_Open procedure?
>
>
>
>
>
> "@Homeonthecouch" wrote:
>>
>> Hi again,
>> I have just noticed that when I open the spreadsheet the cell with the
>> =today() command automatically updates but the macro that is dependant on
>> the answer does not update.
>> I have tried to use refresh F9 but that doesn't work. I can go into the
>> cell
>> and hit enter and that then refreshes the colour assigned to the day.
>> Is there a way of doing this when the spreadsheet opens up? Or is that
>> not
>> advisable?
>>
>> Andrew

>
> --
>
> Dave Peterson



 
Reply With Quote
 
Dave Peterson
Guest
Posts: n/a
 
      20th Mar 2007
Your routine is checking two cells (L22 and L23) for changes made by the
user--not changes made by calculation.

Do they both contain formulas? Or do you just expect the user to change one of
the cells--and why wouldn't the user just type in a date instead of using the
formula =today().

I guess I don't understand enough to help. (Maybe enough to break what you're
really doing, but not enough to help.)

And without knowing too much, you could always just plop that formula into the
cell when the workbook opens.

Behind thisWorkbook (not behind the worksheet and not in a general module).

Option Explicit
Sub Workbook_Open()
me.worksheets("someworksheetnamehere").range("L22").formula = "=Today()"
end sub

=========
I used L22--I don't have any idea if that's good or bad, though.

"@Homeonthecouch" wrote:
>
> Private Sub Worksheet_Change(ByVal Target As Range)
>
> If Target.Cells.Count > 1 Then Exit Sub
> If Intersect(Target, Range("L22:L23")) Is Nothing Then Exit Sub
>
> With Target
> Select Case Weekday(.Value)
> Case Is = vbMonday: .Offset(-1, 0).Resize(2,
> 1).Interior.ColorIndex = 7
> Case Is = vbTuesday: .Offset(-1, 0).Resize(2,
> 1).Interior.ColorIndex = 44
> Case Is = vbWednesday: .Offset(-1, 0).Resize(2,
> 1).Interior.ColorIndex = 6
> Case Is = vbThursday: .Offset(-1, 0).Resize(2,
> 1).Interior.ColorIndex = 4
> Case Is = vbFriday: .Offset(-1, 0).Resize(2,
> 1).Interior.ColorIndex = 8
> Case Is = vbSaturday: .Offset(-1, 0).Resize(2,
> 1).Interior.ColorIndex = 33
> Case Is = vbSunday: .Offset(-1, 0).Resize(2,
> 1).Interior.ColorIndex = 18
> End Select
> End With
>
> End Sub
>
> So I would assume no?
>
> I am totally inexperienced with VBA and have no real idea what I am doing, I
> am learning the methods I find on the net and in these help groups.
> Do I need to change the Worksheet_Change to Worksheet_Calculate?
> The cell updates perfectly when the workbook is opened but the colour
> remains the same as the last time the cell was updated when enter was hit.
>
> --
> Help and patience is as always appreciated
> Thank You
>
> Andrew
>
> "Dave Peterson" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
> > Are you using the worksheet_calculate event? That event recalced for me
> > when I
> > opened a workbook with =today() in a cell (xl2003).
> >
> > If you're not using that event, maybe you could call your macro from the
> > Workbook_Open event or the Auto_Open procedure?
> >
> >
> >
> >
> >
> > "@Homeonthecouch" wrote:
> >>
> >> Hi again,
> >> I have just noticed that when I open the spreadsheet the cell with the
> >> =today() command automatically updates but the macro that is dependant on
> >> the answer does not update.
> >> I have tried to use refresh F9 but that doesn't work. I can go into the
> >> cell
> >> and hit enter and that then refreshes the colour assigned to the day.
> >> Is there a way of doing this when the spreadsheet opens up? Or is that
> >> not
> >> advisable?
> >>
> >> Andrew

> >
> > --
> >
> > Dave Peterson


--

Dave Peterson
 
Reply With Quote
 
@Homeonthecouch
Guest
Posts: n/a
 
      20th Mar 2007
I use the +Today() in cell L23 to automatically update the date and wanted
the day to correspond to a preset colour that I was hoping the conditional
macro would maintain.
I just want the day to change automatically and the colour to follow suite.
No manual input.

Hope this helps you help me

Many thanks for the patience, I appreciate I'm way out of my depth and this
is a simple thing but....its a learning curve, well step actually

Thanks again.

Andrew



"Dave Peterson" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Your routine is checking two cells (L22 and L23) for changes made by the
> user--not changes made by calculation.
>
> Do they both contain formulas? Or do you just expect the user to change
> one of
> the cells--and why wouldn't the user just type in a date instead of using
> the
> formula =today().
>
> I guess I don't understand enough to help. (Maybe enough to break what
> you're
> really doing, but not enough to help.)
>
> And without knowing too much, you could always just plop that formula into
> the
> cell when the workbook opens.
>
> Behind thisWorkbook (not behind the worksheet and not in a general
> module).
>
> Option Explicit
> Sub Workbook_Open()
> me.worksheets("someworksheetnamehere").range("L22").formula = "=Today()"
> end sub
>
> =========
> I used L22--I don't have any idea if that's good or bad, though.
>
> "@Homeonthecouch" wrote:
>>
>> Private Sub Worksheet_Change(ByVal Target As Range)
>>
>> If Target.Cells.Count > 1 Then Exit Sub
>> If Intersect(Target, Range("L22:L23")) Is Nothing Then Exit Sub
>>
>> With Target
>> Select Case Weekday(.Value)
>> Case Is = vbMonday: .Offset(-1, 0).Resize(2,
>> 1).Interior.ColorIndex = 7
>> Case Is = vbTuesday: .Offset(-1, 0).Resize(2,
>> 1).Interior.ColorIndex = 44
>> Case Is = vbWednesday: .Offset(-1, 0).Resize(2,
>> 1).Interior.ColorIndex = 6
>> Case Is = vbThursday: .Offset(-1, 0).Resize(2,
>> 1).Interior.ColorIndex = 4
>> Case Is = vbFriday: .Offset(-1, 0).Resize(2,
>> 1).Interior.ColorIndex = 8
>> Case Is = vbSaturday: .Offset(-1, 0).Resize(2,
>> 1).Interior.ColorIndex = 33
>> Case Is = vbSunday: .Offset(-1, 0).Resize(2,
>> 1).Interior.ColorIndex = 18
>> End Select
>> End With
>>
>> End Sub
>>
>> So I would assume no?
>>
>> I am totally inexperienced with VBA and have no real idea what I am
>> doing, I
>> am learning the methods I find on the net and in these help groups.
>> Do I need to change the Worksheet_Change to Worksheet_Calculate?
>> The cell updates perfectly when the workbook is opened but the colour
>> remains the same as the last time the cell was updated when enter was
>> hit.
>>
>> --
>> Help and patience is as always appreciated
>> Thank You
>>
>> Andrew
>>
>> "Dave Peterson" <(E-Mail Removed)> wrote in message
>> news:(E-Mail Removed)...
>> > Are you using the worksheet_calculate event? That event recalced for
>> > me
>> > when I
>> > opened a workbook with =today() in a cell (xl2003).
>> >
>> > If you're not using that event, maybe you could call your macro from
>> > the
>> > Workbook_Open event or the Auto_Open procedure?
>> >
>> >
>> >
>> >
>> >
>> > "@Homeonthecouch" wrote:
>> >>
>> >> Hi again,
>> >> I have just noticed that when I open the spreadsheet the cell with the
>> >> =today() command automatically updates but the macro that is dependant
>> >> on
>> >> the answer does not update.
>> >> I have tried to use refresh F9 but that doesn't work. I can go into
>> >> the
>> >> cell
>> >> and hit enter and that then refreshes the colour assigned to the day.
>> >> Is there a way of doing this when the spreadsheet opens up? Or is that
>> >> not
>> >> advisable?
>> >>
>> >> Andrew
>> >
>> > --
>> >
>> > Dave Peterson

>
> --
>
> Dave Peterson



 
Reply With Quote
 
Dave Peterson
Guest
Posts: n/a
 
      20th Mar 2007
Use the workbook_open suggestion--but change the address.

"@Homeonthecouch" wrote:
>
> I use the +Today() in cell L23 to automatically update the date and wanted
> the day to correspond to a preset colour that I was hoping the conditional
> macro would maintain.
> I just want the day to change automatically and the colour to follow suite.
> No manual input.
>
> Hope this helps you help me
>
> Many thanks for the patience, I appreciate I'm way out of my depth and this
> is a simple thing but....its a learning curve, well step actually
>
> Thanks again.
>
> Andrew
>
> "Dave Peterson" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
> > Your routine is checking two cells (L22 and L23) for changes made by the
> > user--not changes made by calculation.
> >
> > Do they both contain formulas? Or do you just expect the user to change
> > one of
> > the cells--and why wouldn't the user just type in a date instead of using
> > the
> > formula =today().
> >
> > I guess I don't understand enough to help. (Maybe enough to break what
> > you're
> > really doing, but not enough to help.)
> >
> > And without knowing too much, you could always just plop that formula into
> > the
> > cell when the workbook opens.
> >
> > Behind thisWorkbook (not behind the worksheet and not in a general
> > module).
> >
> > Option Explicit
> > Sub Workbook_Open()
> > me.worksheets("someworksheetnamehere").range("L22").formula = "=Today()"
> > end sub
> >
> > =========
> > I used L22--I don't have any idea if that's good or bad, though.
> >
> > "@Homeonthecouch" wrote:
> >>
> >> Private Sub Worksheet_Change(ByVal Target As Range)
> >>
> >> If Target.Cells.Count > 1 Then Exit Sub
> >> If Intersect(Target, Range("L22:L23")) Is Nothing Then Exit Sub
> >>
> >> With Target
> >> Select Case Weekday(.Value)
> >> Case Is = vbMonday: .Offset(-1, 0).Resize(2,
> >> 1).Interior.ColorIndex = 7
> >> Case Is = vbTuesday: .Offset(-1, 0).Resize(2,
> >> 1).Interior.ColorIndex = 44
> >> Case Is = vbWednesday: .Offset(-1, 0).Resize(2,
> >> 1).Interior.ColorIndex = 6
> >> Case Is = vbThursday: .Offset(-1, 0).Resize(2,
> >> 1).Interior.ColorIndex = 4
> >> Case Is = vbFriday: .Offset(-1, 0).Resize(2,
> >> 1).Interior.ColorIndex = 8
> >> Case Is = vbSaturday: .Offset(-1, 0).Resize(2,
> >> 1).Interior.ColorIndex = 33
> >> Case Is = vbSunday: .Offset(-1, 0).Resize(2,
> >> 1).Interior.ColorIndex = 18
> >> End Select
> >> End With
> >>
> >> End Sub
> >>
> >> So I would assume no?
> >>
> >> I am totally inexperienced with VBA and have no real idea what I am
> >> doing, I
> >> am learning the methods I find on the net and in these help groups.
> >> Do I need to change the Worksheet_Change to Worksheet_Calculate?
> >> The cell updates perfectly when the workbook is opened but the colour
> >> remains the same as the last time the cell was updated when enter was
> >> hit.
> >>
> >> --
> >> Help and patience is as always appreciated
> >> Thank You
> >>
> >> Andrew
> >>
> >> "Dave Peterson" <(E-Mail Removed)> wrote in message
> >> news:(E-Mail Removed)...
> >> > Are you using the worksheet_calculate event? That event recalced for
> >> > me
> >> > when I
> >> > opened a workbook with =today() in a cell (xl2003).
> >> >
> >> > If you're not using that event, maybe you could call your macro from
> >> > the
> >> > Workbook_Open event or the Auto_Open procedure?
> >> >
> >> >
> >> >
> >> >
> >> >
> >> > "@Homeonthecouch" wrote:
> >> >>
> >> >> Hi again,
> >> >> I have just noticed that when I open the spreadsheet the cell with the
> >> >> =today() command automatically updates but the macro that is dependant
> >> >> on
> >> >> the answer does not update.
> >> >> I have tried to use refresh F9 but that doesn't work. I can go into
> >> >> the
> >> >> cell
> >> >> and hit enter and that then refreshes the colour assigned to the day.
> >> >> Is there a way of doing this when the spreadsheet opens up? Or is that
> >> >> not
> >> >> advisable?
> >> >>
> >> >> Andrew
> >> >
> >> > --
> >> >
> >> > Dave Peterson

> >
> > --
> >
> > Dave Peterson


--

Dave Peterson
 
Reply With Quote
 
@Homeonthecouch
Guest
Posts: n/a
 
      20th Mar 2007
OOOH I like that little trick
Many thanks that could come in rather useful for a whole host of things
It will be a great get around to stop people deleting/altering data in
cells.


Once again, Many Thanks

Andrew



"Dave Peterson" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Use the workbook_open suggestion--but change the address.
>
> "@Homeonthecouch" wrote:
>>
>> I use the +Today() in cell L23 to automatically update the date and
>> wanted
>> the day to correspond to a preset colour that I was hoping the
>> conditional
>> macro would maintain.
>> I just want the day to change automatically and the colour to follow
>> suite.
>> No manual input.
>>
>> Hope this helps you help me
>>
>> Many thanks for the patience, I appreciate I'm way out of my depth and
>> this
>> is a simple thing but....its a learning curve, well step actually
>>
>> Thanks again.
>>
>> Andrew
>>
>> "Dave Peterson" <(E-Mail Removed)> wrote in message
>> news:(E-Mail Removed)...
>> > Your routine is checking two cells (L22 and L23) for changes made by
>> > the
>> > user--not changes made by calculation.
>> >
>> > Do they both contain formulas? Or do you just expect the user to
>> > change
>> > one of
>> > the cells--and why wouldn't the user just type in a date instead of
>> > using
>> > the
>> > formula =today().
>> >
>> > I guess I don't understand enough to help. (Maybe enough to break what
>> > you're
>> > really doing, but not enough to help.)
>> >
>> > And without knowing too much, you could always just plop that formula
>> > into
>> > the
>> > cell when the workbook opens.
>> >
>> > Behind thisWorkbook (not behind the worksheet and not in a general
>> > module).
>> >
>> > Option Explicit
>> > Sub Workbook_Open()
>> > me.worksheets("someworksheetnamehere").range("L22").formula =
>> > "=Today()"
>> > end sub
>> >
>> > =========
>> > I used L22--I don't have any idea if that's good or bad, though.
>> >
>> > "@Homeonthecouch" wrote:
>> >>
>> >> Private Sub Worksheet_Change(ByVal Target As Range)
>> >>
>> >> If Target.Cells.Count > 1 Then Exit Sub
>> >> If Intersect(Target, Range("L22:L23")) Is Nothing Then Exit Sub
>> >>
>> >> With Target
>> >> Select Case Weekday(.Value)
>> >> Case Is = vbMonday: .Offset(-1, 0).Resize(2,
>> >> 1).Interior.ColorIndex = 7
>> >> Case Is = vbTuesday: .Offset(-1, 0).Resize(2,
>> >> 1).Interior.ColorIndex = 44
>> >> Case Is = vbWednesday: .Offset(-1, 0).Resize(2,
>> >> 1).Interior.ColorIndex = 6
>> >> Case Is = vbThursday: .Offset(-1, 0).Resize(2,
>> >> 1).Interior.ColorIndex = 4
>> >> Case Is = vbFriday: .Offset(-1, 0).Resize(2,
>> >> 1).Interior.ColorIndex = 8
>> >> Case Is = vbSaturday: .Offset(-1, 0).Resize(2,
>> >> 1).Interior.ColorIndex = 33
>> >> Case Is = vbSunday: .Offset(-1, 0).Resize(2,
>> >> 1).Interior.ColorIndex = 18
>> >> End Select
>> >> End With
>> >>
>> >> End Sub
>> >>
>> >> So I would assume no?
>> >>
>> >> I am totally inexperienced with VBA and have no real idea what I am
>> >> doing, I
>> >> am learning the methods I find on the net and in these help groups.
>> >> Do I need to change the Worksheet_Change to Worksheet_Calculate?
>> >> The cell updates perfectly when the workbook is opened but the colour
>> >> remains the same as the last time the cell was updated when enter was
>> >> hit.
>> >>
>> >> --
>> >> Help and patience is as always appreciated
>> >> Thank You
>> >>
>> >> Andrew
>> >>
>> >> "Dave Peterson" <(E-Mail Removed)> wrote in message
>> >> news:(E-Mail Removed)...
>> >> > Are you using the worksheet_calculate event? That event recalced
>> >> > for
>> >> > me
>> >> > when I
>> >> > opened a workbook with =today() in a cell (xl2003).
>> >> >
>> >> > If you're not using that event, maybe you could call your macro from
>> >> > the
>> >> > Workbook_Open event or the Auto_Open procedure?
>> >> >
>> >> >
>> >> >
>> >> >
>> >> >
>> >> > "@Homeonthecouch" wrote:
>> >> >>
>> >> >> Hi again,
>> >> >> I have just noticed that when I open the spreadsheet the cell with
>> >> >> the
>> >> >> =today() command automatically updates but the macro that is
>> >> >> dependant
>> >> >> on
>> >> >> the answer does not update.
>> >> >> I have tried to use refresh F9 but that doesn't work. I can go into
>> >> >> the
>> >> >> cell
>> >> >> and hit enter and that then refreshes the colour assigned to the
>> >> >> day.
>> >> >> Is there a way of doing this when the spreadsheet opens up? Or is
>> >> >> that
>> >> >> not
>> >> >> advisable?
>> >> >>
>> >> >> Andrew
>> >> >
>> >> > --
>> >> >
>> >> > Dave Peterson
>> >
>> > --
>> >
>> > Dave Peterson

>
> --
>
> Dave Peterson



 
Reply With Quote
 
Dave Peterson
Guest
Posts: n/a
 
      20th Mar 2007
If you're gonna do this kind of thing, you may find it better to name the ranges
(insert|Name|define).

Then if you insert or delete rows or columns, you won't have to worry about
changing all the addresses in your code.

"@Homeonthecouch" wrote:
>
> OOOH I like that little trick
> Many thanks that could come in rather useful for a whole host of things
> It will be a great get around to stop people deleting/altering data in
> cells.
>
> Once again, Many Thanks
>
> Andrew
>
> "Dave Peterson" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
> > Use the workbook_open suggestion--but change the address.
> >
> > "@Homeonthecouch" wrote:
> >>
> >> I use the +Today() in cell L23 to automatically update the date and
> >> wanted
> >> the day to correspond to a preset colour that I was hoping the
> >> conditional
> >> macro would maintain.
> >> I just want the day to change automatically and the colour to follow
> >> suite.
> >> No manual input.
> >>
> >> Hope this helps you help me
> >>
> >> Many thanks for the patience, I appreciate I'm way out of my depth and
> >> this
> >> is a simple thing but....its a learning curve, well step actually
> >>
> >> Thanks again.
> >>
> >> Andrew
> >>
> >> "Dave Peterson" <(E-Mail Removed)> wrote in message
> >> news:(E-Mail Removed)...
> >> > Your routine is checking two cells (L22 and L23) for changes made by
> >> > the
> >> > user--not changes made by calculation.
> >> >
> >> > Do they both contain formulas? Or do you just expect the user to
> >> > change
> >> > one of
> >> > the cells--and why wouldn't the user just type in a date instead of
> >> > using
> >> > the
> >> > formula =today().
> >> >
> >> > I guess I don't understand enough to help. (Maybe enough to break what
> >> > you're
> >> > really doing, but not enough to help.)
> >> >
> >> > And without knowing too much, you could always just plop that formula
> >> > into
> >> > the
> >> > cell when the workbook opens.
> >> >
> >> > Behind thisWorkbook (not behind the worksheet and not in a general
> >> > module).
> >> >
> >> > Option Explicit
> >> > Sub Workbook_Open()
> >> > me.worksheets("someworksheetnamehere").range("L22").formula =
> >> > "=Today()"
> >> > end sub
> >> >
> >> > =========
> >> > I used L22--I don't have any idea if that's good or bad, though.
> >> >
> >> > "@Homeonthecouch" wrote:
> >> >>
> >> >> Private Sub Worksheet_Change(ByVal Target As Range)
> >> >>
> >> >> If Target.Cells.Count > 1 Then Exit Sub
> >> >> If Intersect(Target, Range("L22:L23")) Is Nothing Then Exit Sub
> >> >>
> >> >> With Target
> >> >> Select Case Weekday(.Value)
> >> >> Case Is = vbMonday: .Offset(-1, 0).Resize(2,
> >> >> 1).Interior.ColorIndex = 7
> >> >> Case Is = vbTuesday: .Offset(-1, 0).Resize(2,
> >> >> 1).Interior.ColorIndex = 44
> >> >> Case Is = vbWednesday: .Offset(-1, 0).Resize(2,
> >> >> 1).Interior.ColorIndex = 6
> >> >> Case Is = vbThursday: .Offset(-1, 0).Resize(2,
> >> >> 1).Interior.ColorIndex = 4
> >> >> Case Is = vbFriday: .Offset(-1, 0).Resize(2,
> >> >> 1).Interior.ColorIndex = 8
> >> >> Case Is = vbSaturday: .Offset(-1, 0).Resize(2,
> >> >> 1).Interior.ColorIndex = 33
> >> >> Case Is = vbSunday: .Offset(-1, 0).Resize(2,
> >> >> 1).Interior.ColorIndex = 18
> >> >> End Select
> >> >> End With
> >> >>
> >> >> End Sub
> >> >>
> >> >> So I would assume no?
> >> >>
> >> >> I am totally inexperienced with VBA and have no real idea what I am
> >> >> doing, I
> >> >> am learning the methods I find on the net and in these help groups.
> >> >> Do I need to change the Worksheet_Change to Worksheet_Calculate?
> >> >> The cell updates perfectly when the workbook is opened but the colour
> >> >> remains the same as the last time the cell was updated when enter was
> >> >> hit.
> >> >>
> >> >> --
> >> >> Help and patience is as always appreciated
> >> >> Thank You
> >> >>
> >> >> Andrew
> >> >>
> >> >> "Dave Peterson" <(E-Mail Removed)> wrote in message
> >> >> news:(E-Mail Removed)...
> >> >> > Are you using the worksheet_calculate event? That event recalced
> >> >> > for
> >> >> > me
> >> >> > when I
> >> >> > opened a workbook with =today() in a cell (xl2003).
> >> >> >
> >> >> > If you're not using that event, maybe you could call your macro from
> >> >> > the
> >> >> > Workbook_Open event or the Auto_Open procedure?
> >> >> >
> >> >> >
> >> >> >
> >> >> >
> >> >> >
> >> >> > "@Homeonthecouch" wrote:
> >> >> >>
> >> >> >> Hi again,
> >> >> >> I have just noticed that when I open the spreadsheet the cell with
> >> >> >> the
> >> >> >> =today() command automatically updates but the macro that is
> >> >> >> dependant
> >> >> >> on
> >> >> >> the answer does not update.
> >> >> >> I have tried to use refresh F9 but that doesn't work. I can go into
> >> >> >> the
> >> >> >> cell
> >> >> >> and hit enter and that then refreshes the colour assigned to the
> >> >> >> day.
> >> >> >> Is there a way of doing this when the spreadsheet opens up? Or is
> >> >> >> that
> >> >> >> not
> >> >> >> advisable?
> >> >> >>
> >> >> >> Andrew
> >> >> >
> >> >> > --
> >> >> >
> >> >> > Dave Peterson
> >> >
> >> > --
> >> >
> >> > Dave Peterson

> >
> > --
> >
> > Dave Peterson


--

Dave Peterson
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Auto Update a sheet through Macro Chetu Microsoft Excel Programming 4 7th Aug 2009 12:26 PM
Workgroup Macro? Auto-Update? Joshua Microsoft Excel Programming 1 14th Feb 2009 05:22 PM
Macro Auto-update of data labels brandon.j.rapp@gmail.com Microsoft Excel Worksheet Functions 0 7th Aug 2007 04:17 PM
Stop auto update of filter macro? =?Utf-8?B?UEcgT3JpZWw=?= Microsoft Excel Programming 4 16th Nov 2006 03:44 PM
Need an auto update formula macro foxspirit Microsoft Excel Programming 2 14th Feb 2006 05:00 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 01:31 AM.