Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Formatting Text by when last modified

Hi,

I have a spreadsheet with a large amount of text values held on it.

In order to improve usability I have been asked to implement a
formatting system whereby any cell which has been modified in the last
2 days is highlighted (e.g. red text).

After the 2 day period, the text is to revert back to blank text
formatting.

Any help, advice or alternative solutions would be much appreciated.

Many thanks.

Richard

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Formatting Text by when last modified

Use two worksheets.

In the first worksheet include a change event macro that records today's
date in sheet2. For example, if Z100 is changed in sheet1, the macro will
record today's date in sheet2!Z100 and format the text in sheet1!Z100 to red.

The next macro (in a standard module) will scan thru every cell on sheet2
looking for a date. If a date is found, and the date is more than two day's
stale, then the text color of the equivalent cell in sheet1 is changed back
to black. the second macro should be run once a day.
--
Gary's Student


" wrote:

Hi,

I have a spreadsheet with a large amount of text values held on it.

In order to improve usability I have been asked to implement a
formatting system whereby any cell which has been modified in the last
2 days is highlighted (e.g. red text).

After the 2 day period, the text is to revert back to blank text
formatting.

Any help, advice or alternative solutions would be much appreciated.

Many thanks.

Richard


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Formatting Text by when last modified

Many thanks for your help - I've got the first part working, but I cant
seem to be able to set up the second macro, which searches for =NOW()
and =NOW()-2 -- any ideas?



Gary''s Student wrote:
Use two worksheets.

In the first worksheet include a change event macro that records today's
date in sheet2. For example, if Z100 is changed in sheet1, the macro will
record today's date in sheet2!Z100 and format the text in sheet1!Z100 to red.

The next macro (in a standard module) will scan thru every cell on sheet2
looking for a date. If a date is found, and the date is more than two day's
stale, then the text color of the equivalent cell in sheet1 is changed back
to black. the second macro should be run once a day.
--
Gary's Student


" wrote:

Hi,

I have a spreadsheet with a large amount of text values held on it.

In order to improve usability I have been asked to implement a
formatting system whereby any cell which has been modified in the last
2 days is highlighted (e.g. red text).

After the 2 day period, the text is to revert back to blank text
formatting.

Any help, advice or alternative solutions would be much appreciated.

Many thanks.

Richard



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Formatting Text by when last modified

Second macro might look like:

Sub gsnu()
Sheets("Sheet2").Activate
For Each r In ActiveSheet.UsedRange
If IsDate(r.Value) Then
If Now() - r.Value 2 Then
s = r.Address
Sheets("Sheet1").Activate
With Range(s).Font
.ColorIndex = xlAutomatic
End With
Sheets("Sheet2").Activate
End If
End If
Next
End Sub

--
Gary''s Student


" wrote:

Hi,

I have a spreadsheet with a large amount of text values held on it.

In order to improve usability I have been asked to implement a
formatting system whereby any cell which has been modified in the last
2 days is highlighted (e.g. red text).

After the 2 day period, the text is to revert back to blank text
formatting.

Any help, advice or alternative solutions would be much appreciated.

Many thanks.

Richard


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Text join formulas working but act as straight text when modified akkrug New Users to Excel 3 May 14th 08 02:27 PM
Formula Text String: Formatting Text and Numbers? dj479794 Excel Discussion (Misc queries) 5 June 30th 07 12:19 AM
Conditional Formatting based on text within a cell w/ text AND num Shirley Excel Worksheet Functions 2 December 22nd 06 01:40 AM
Modified VB Code for Converting Number to Text shashidharga[_4_] Excel Programming 1 October 4th 04 07:18 PM
Modified VB Code for Converting Number to Text shashidharga[_3_] Excel Programming 4 October 3rd 04 01:11 PM


All times are GMT +1. The time now is 08:13 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"