LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Pro Football formula automation

I posted a similar question on another board, haven't had luck yet.
Will try to explain it better here.
In column B, I have opponents for teams in column A. I have empty
cells between each team in column A also.
Ex: A2:A17 is Arizona, B2:B17 is San Fransisco, Seattle, Baltimore,
etc. (Opponents of Arizona)

Then I skip 2 lines and list Atlanta in A20:A37 and list their
opponents in B20:B37, and I do this for all 32 teams. The last entry
ends on row 638. I have Named Ranges for each team, but the names
differ from the team names.

Arizona's Named Range is "Ari_Avg", Atlanta's is "Atl_Avg", San
Fransisco's is SF_Avg etc.

What I need to do (in VBA I suppose), is write a formula in column G
that looks in column B, and if B2 text is San Fransisco, then write
the formula "=AVERAGE(SF_Avg)"

I have searched Help and Newsgroups for an answer, and have tried
different methods, but can't get my code to work. I tried using 32
if's (one for each team) but keep getting errors, like If without
block If. Would it be easier to name my Named Ranges to equal the text
in B2:B638, then use Offset, like another guy tried to help me with?
Shoot, I couldn't even make that work.

I think I need something like:
If c.Value(B2:B638) = San Fransisco Then (G2:G638).Formula =
"AVERAGE(SF_Avg)"

Hope someone can help. Thanks.

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Formula for evaluating predictions - Fantasy Football League gavin Excel Discussion (Misc queries) 9 July 4th 10 02:41 AM
Formula for Football (Soccer) Prediction League genius7082 Excel Discussion (Misc queries) 1 August 10th 08 09:39 PM
Supressing the ctrl-c and other keys during word automation in automation apondu Excel Programming 0 July 19th 07 10:10 PM
Fantasy Football Datbase or Formula Dave Excel Discussion (Misc queries) 0 July 8th 05 09:18 PM
Football Predictions Spreadsheet formula problem Glenn Richardson Excel Programming 2 September 25th 04 10:47 PM


All times are GMT +1. The time now is 12:46 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"