Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default Maximum Value of a Cell over a series of calculations

Basically this is what I am trying to accomplish:

Column #1 -
This column will contain a formula that updates when an variable cell
value is changed elsewhere in the spreadsheet.

Column #2 -
I would like this column to update and display the value in Column #1
ONLY when the value in Column #1 is greater than the current value in
Column #2.

This should produce the maximum value over a long series of
calculations as I change a variable. The tricky part is I would like
to do this over a range of 300 cells without typing in a ton of VBA
code. If anyone has any suggestions please let me know.

Thanks,

Bryan

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 459
Default Maximum Value of a Cell over a series of calculations

Kypp wrote:
Basically this is what I am trying to accomplish:

Column #1 -
This column will contain a formula that updates when an variable cell
value is changed elsewhere in the spreadsheet.

Column #2 -
I would like this column to update and display the value in Column #1
ONLY when the value in Column #1 is greater than the current value in
Column #2.

This should produce the maximum value over a long series of
calculations as I change a variable. The tricky part is I would like
to do this over a range of 300 cells without typing in a ton of VBA
code. If anyone has any suggestions please let me know.

Thanks,

Bryan



Hi Bryan,

Because you don't want to use VBA, I think you need a third column because a
cell can have or a formula or a value, not both depending on a condition.

So if we assume you use column A, B and C, starting from row 2 (I assume you
have headers in row 1), you will have your formula in column A, some values
in column B and you can type this formula in C2:

=IF(A2B2,A2,B2)

Now you can drag the cell C2 across the row. If you want you can also hide
the column B with the fixed values.


--
Hope I helped you.

Thanks in advance for your feedback.

Ciao

Franz Verga from Italy


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default Maximum Value of a Cell over a series of calculations

Franz,

Thanks for your help. This isn't quite what I was looking for though
since the values that I am comparing Column A to are not fixed values
but all the previous values (really just the last iteration) of Column
A. Recalculating the previous iteration of Column A would and
displaying it in Column B would work as you discribed but that is a lot
more spreadsheet to write and woulnd end up complicating things even
more.

When I wrote this question I had a way of doing it in VBA it just
required 300 lines of code for each comparison that I wanted to do and
it also required a bit of computer muscle. I have since figured out
how to do it in about 10 lines of code for each comparison but it still
slows down my program and forces me to disable screen updating. This
isn't so bad except that it would be useful to be able to animate the
problem I am analysing in realtime. So I am not opposed to VBA just
trying to streamline the code so that it runs more smoothly

Hi Bryan,

Because you don't want to use VBA, I think you need a third column because a
cell can have or a formula or a value, not both depending on a condition.

So if we assume you use column A, B and C, starting from row 2 (I assume you
have headers in row 1), you will have your formula in column A, some values
in column B and you can type this formula in C2:

=IF(A2B2,A2,B2)

Now you can drag the cell C2 across the row. If you want you can also hide
the column B with the fixed values.


--
Hope I helped you.

Thanks in advance for your feedback.

Ciao

Franz Verga from Italy


Reply
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
excel chart maximum series should more than 255 series kameking Charts and Charting in Excel 5 August 22nd 10 10:52 AM
insert date Larry Excel Worksheet Functions 28 July 15th 06 02:41 AM
Compiling macro based on cell values simonsmith Excel Discussion (Misc queries) 1 May 16th 06 08:31 PM
How do I change a number in one cell to change a series of cells? lance559 Excel Discussion (Misc queries) 2 January 13th 06 08:56 PM
Maximum Number of Cell Formats Jim Allen Excel Discussion (Misc queries) 4 April 19th 05 07:07 PM


All times are GMT +1. The time now is 07:44 PM.

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

About Us

"It's about Microsoft Excel"