PC Review


Reply
Thread Tools Rate Thread

Analysis of data

 
 
=?Utf-8?B?RGFu?=
Guest
Posts: n/a
 
      22nd Sep 2006
Hello

I have 52 sheets in the same workbook.
Sheet 51 is a summary sheet, sheets 1 - 50 are detail sheets.
I would like sheet 52 to be an analysis sheet.
In the top corner of sheet 52 I would like to be able to put a code
reference on and below it, it then lists all of the sheets that contain that
code and what value the codes has next to it.

What is the easiest way of doing this?

Thanks

--
Cheers
 
Reply With Quote
 
 
 
 
vezerid
Guest
Posts: n/a
 
      22nd Sep 2006
Dan
the following macro will read a code in A1 of a sheet named Analysis.
It will then clear the area below and produce a 2-col output, sheet
name and value next to the code. It assumes that your detail sheets are
before summary and analysis. It also assumes that a code appears max
once per sheet.

Sub Analysis()
Dim codecell As Range
nextrow = 2
cod = Sheets("Analysis").Range("A1").Value
Sheets("Analysis").Range("A2:B1000").ClearContents
For i = 1 To 50
Set codecell = Sheets(i).Cells.Find(cod)
If Not codecell Is Nothing Then
Sheets("Analysis").Cells(nextrow, 1) = Sheets(i).Name
Sheets("Analysis").Cells(nextrow, 2) = codecell.Offset(0, 1)
nextrow = nextrow + 1
End If
Next i
End Sub

You can further automate the process by using an event procedure for
your Analysis worksheet:

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Not Intersect(Target, Range("A1")) Is Nothing Then Call Analysis
End Sub

With this, each time a code is changed in Analysis!A1, the macro will
run automatically.

Does this help?
Kostis Vezerides

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Q: Automate the Fourier Analysis - Data Analysis Tool pinkpanther Microsoft Excel Discussion 0 14th Jan 2011 04:04 PM
Analysis Toolpak-Confidence Level and data analysis questions MH Microsoft Excel Worksheet Functions 0 3rd Jan 2009 06:15 PM
'Analysis Toolpak' is checked, but 'Data Analysis' did not appear =?Utf-8?B?d29uZGVyaW5n?= Microsoft Excel Crashes 0 16th Aug 2005 02:07 AM
Analysis ToolPak installed but no Data Analysis option =?Utf-8?B?RXJpYyBTdGVwaGVucw==?= Microsoft Excel Misc 3 2nd Feb 2005 09:17 PM
Any performance analysis tools can easily to read & analysis CSV data come from Windows Performance Monitor? =?Utf-8?B?QWxleGFuZGVyIEJyb3du?= Microsoft Windows 2000 2 30th Jan 2004 03:30 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:27 AM.