Create automatic worksheet and graph title




My dad uses a spreadsheet to track attendance in the classes he teaches. To add nice-looking titles to his attendance reports, I use the following Excel formula: =concatenate("Attendance sheet for ", text(today(), "mmmm, yyyy")). The result is "Attendance sheet for September, 1997".
- Andrew Kooi


Thanks for the tip, Andrew. The concatenate function used in Excel and Quattro Pro supplants the old concatenation operator &, which works in any spreadsheet program. So you could have written your formula ="Attendance sheet for "&text(today(), "mmmm, yyyy"), which to my eye is a little easier to read. 1-2-3's @datestring function can come close to this. The formula +"Attendance sheet for "&@datestring(@now) yields "Attendance sheet for 9/1/97".
But things get a bit trickier for 1-2-3 or Quattro Pro users who want to duplicate your results exactly: +"Attendance sheet for "&@choose(@month (@now)-1,"January","February","March","April","May","June","July","August","September","October","November","December") &" 19"&@string(@year(@now),0)
Incidentally, you can place such a formula on an Excel chart. After you've built your chart, enter the formula into any cell (say A1 on Sheet1), then double-click the chart if it's embedded, or select it if it's on a chart sheet. Click outside the chart area, enter Sheet1!&A$1 on the formula bar, and press <Enter>. You'll get a text box that displays the contents of the cell. Drag it into position, and format it as you would any other chart text.
In 1-2-3 or Quattro Pro, you can make the label appear in report headers and footers by selecting File--Page Setup and then entering a backslash and the cell address in the Header or Footer box. For example, the command \A:A1 displays the contents of cell A1 on Sheet A.
This also works for chart titles, except in 1-2-3 Release 5.0, in which you need to select the chart and then select Chart--Headings. In the Title section of the dialogue box, enter A1 (or the address of the cell that contains the text you want to use), and click the Cell box. Then click OK.
- Richard Scoville


Category: Spreadsheet
Issue: Oct 1997
Pages: 167

These Web pages are produced by Australian PC World © 1997 IDG Communications