Couple of ways to do this.
Event code which is triggered by a double-click on a cell with the
appropriate text in it..............week1 or week52.....not case-sensitive
Option Compare Text
Private Sub Worksheet_BeforeDoubleClick(ByVal _
Target As Range, Cancel As Boolean)
If Left(Target, 4) <> "week" Then GoTo ws_exit
Target.Resize(10, 8).PrintOut
ws_exit:
Cancel = True
End Sub
Right-click on the Sheet tab and "View Code". Copy/paste the code into that
module. Edit the resize(10, 8) to suit..............set now for a 10 row, 8
column range...........A1:H10 for example.
A macro which asks for user input of week number.
Sub print_week()
Dim weeknum As Integer
weeknum = InputBox("Enter a Number from 1 to 52")
With Worksheets(1).UsedRange
Set c = .Find("week" & weeknum, LookIn:=xlValues, lookat:=xlPart)
If Not c Is Nothing Then
FirstAddress = c.Address
c.Resize(10, 8).PrintOut
End If
End With
End Sub
This macro would be placed in a General module in your workbook.
Note.................neither has error-checking.
See Ron de Bruin's site for where and how to store macros and code.
http://www.rondebruin.nl/code.htm
Gord