Color different people's source code

jencajenca

New Member
Joined
Jan 25, 2009
Messages
8
Hi!

I am wondering if there is any good way of coloring different sections of the source code in excel to show what different programmers have added?

Thanks for the help!
 

Some videos you may like

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.

jencajenca

New Member
Joined
Jan 25, 2009
Messages
8
True, i was mostly wondering if there was a color i could use for when i added new changes, so they would be easily seen. But i guess i just have to add a searchable key word in a comment then. Thanks for the help though!
 

Joe Was

MrExcel MVP
Joined
Feb 19, 2002
Messages
7,539
The Track Changes Option in Excel will show all changes made and highlight them on the sheet, if by code you mean VBA macro code then no!

Turn on change tracking for a workbook

  1. On the Tools menu, click Share Workbook, and then click the Editing tab.<LI class=LPROC>Select the Allow changes by more than one user at the same time check box. <LI class=LPROC>Click the Advanced tab. <LI class=LPROC>Under Track changes, click Keep change history for, and in the Days box, type the number of days of the change history that you want to keep. Be sure to enter a large-enough number of days because Microsoft Excel permanently erases any change history older than this number of days.
  2. Click OK, and if prompted to save the file, click OK.
Note Turning on change tracking also shares the workbook. </INPUT>
 
Last edited:

Norie

Well-known Member
Joined
Apr 28, 2004
Messages
75,564
Office Version
365
Platform
Windows
jencajenca

How would colouring the code make it be easily seen who altered/created it?

You can change the colour coding for code but not for individual sections of code.

And even if you could I think you'd end up actually making itharder to follow and/or harder to read.:eek:

Also if you have multiple people creating/altering code, and you want to colour each alteration/whatever you could end up with some sort of 'rainbow' effect.

Now, personally, I would regard that as just confusing and probably cause a few headaches.:)
 

jencajenca

New Member
Joined
Jan 25, 2009
Messages
8
Yeah, i see your point, although i was more so thinking "old code - black, new code - red until the programmers gone through it together and accepted the changes".
 

Sal Paradise

Well-known Member
Joined
Oct 23, 2006
Messages
2,457
You could make 2 different modules:
"Accepted"
"Under Review"

And then have those functions called from wherever needed, then copy-pasted to the new location after review. That would keep the code distinct, though it may not work for 100% of items.
 

Qldguy30au

Board Regular
Joined
Jan 15, 2009
Messages
190
Im curious if on this same topic, Conditional Formatting can take into consideration the Date in which that cell was last modified?

eg: Track Changes does show the last change to the cell with a date and time.

Can Conditional Formatting be used for the cell color based on date the cell was last modified? Perhaps this is what he seeks?
 

Norie

Well-known Member
Joined
Apr 28, 2004
Messages
75,564
Office Version
365
Platform
Windows
Im curious if on this same topic, Conditional Formatting can take into consideration the Date in which that cell was last modified?

eg: Track Changes does show the last change to the cell with a date and time.

Can Conditional Formatting be used for the cell color based on date the cell was last modified? Perhaps this is what he seeks?
The OP want's to highlight changes in VBA code not changes on a worksheet.:)
 

jencajenca

New Member
Joined
Jan 25, 2009
Messages
8
Good idea with the modules, i'll give it a try, thanks! And yes, i did mean changes in the code, not the cells :)

//Jenny
 

Watch MrExcel Video

Forum statistics

Threads
1,099,699
Messages
5,470,257
Members
406,686
Latest member
BNR_ 1980

This Week's Hot Topics

Top