Excel

  • Buffer
  • Sharebar
  • Buffer
jethro's picture

Developing in Excel 2007

I much prefer working in Excel 2007 to Excel 2003. Despite the issues with backward compatibility, there are a lot of advantages and benefits to using the new version.

Some little things that have been changed are

The previous limit on nested brackets in formulas from 7 has been increased to 64. I used this today

The number of columns and rows has increased. I used this today.

I had to develop a file for a client that involved a complex work roster arrangement to calculate days off in repeating 2, 3 or 4 week cycles for the next 20 years.

Here is the nested formula that got me the logic for a roster.

=IF($X5>=AJ$4,$X$4,IF($Y5>=AJ$4,$Y$4,IF($Z5>=AJ$4,$Z$4,IF($AA5>=AJ$4,$AA$4,IF($AB5>=AJ$4,$AB$4, IF($AC5>=AJ$4,$AC$4,IF($AD5>=AJ$4,$AD$4,IF($AE5>=AJ$4,$AE$4,IF($AF5>=AJ$4,$AF$4,$AG$4)))))))))

I then used one formula to generate over 600,000 cells and create a map that looks like this.

jethro's picture

Advanced Excel Applications

Joseph Chirilov writes an Excel blog for the MSDN website. He often gets Excel writers to contribute.

Today I want to highlight two recent articles from Joseph’s site.

The first written by Mark Gillis is How to Create a Perpetual Yearly Calendar in Excel. The information about dates in here is very useful even if you don’t need to create a calendar. I recommend reading this if you have ever had problems managing dates in Excel.

The second one is a great example of building a complex application. Charlie Ellis, a Program Manager on the Excel team, shares a spreadsheet he built in Excel for solving Sudoku puzzles.

Building a Basic, Understandable Sudoku Solver Using Excel Iterative Calculation - Part 1/2

Building a Basic, Understandable Sudoku Solver Using Excel Iterative Calculation - Part 2/2

Enjoy.

jethro's picture

Conditional formatting in Excel 2007 - entire row colours

I had an interesting question about conditional formatting posed in the comments by Stephen.

In a new sheet, I am trying to make a whole row turn red, green or amber depending on the value of one cell in that row, so I can easily see which jobs we have won, lost or are pending. Any 'IF' conditional formula I write gets thrown out by Excel. What am I doing wrong?

I promised him an answer so here it is.

For this exercise I am making some assumptions.

  • You are using Excel 2007 format Excel spreadsheet (.xlsx or .xlsm). These instructions will not work in detail for Excel 2003, though the concept is similar.
  • That there are 3 conditions we  are looking for. Of course Excel 2007 allows more than 3 conditions so you can add more if you need. (One of the improvements on Excel 2003 that only allowed 3 rules)
  • That the entire row is needed to be coloured. If you need a smaller section than change the formulas accordingly.
  • That the entire worksheet needs this formatting. If you need a smaller section than change the formulas accordingly.
  • That the conditional formats are going to be based on a cell that returns a specific result based on some other rule.
jethro's picture

Using the VBA recorder and editor in Excel

I promised to start writing a series of VBA primers. This is the first one.

For many using Excel is a daily thing. From office secretaries who manage the petty cash through to financial whizzkids who monitor stocks and bonds, Excel is a very versatile tool. It also has a lot of potential for automating repetitive tasks easily by being able to create macros.

imageA macro is a simply a “recorded set of instructions”. These can be as simple as saving two different sets of print options so you don’t have to continually change them. Basically the concept of a Macro is that you can get the computer to record the key and mouse strokes you use and save them so they can be repeated. While the reality is that the macro that is recorded is written in a language called VBA (visual Basic for Applications) this is irrelevant to people who first start using it.