Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 14
Default Maximum of selection

Greetings !

Having selected a block say 4 columns wide and 12 rows
long, I want to establish the maximum value of the
selected cells in a particular column.

I have tried
myMax = MAX( _
Selection.FirstCol & _
Selection.FirstRow & ":" & _
Selection.FirstCol & _
Selection.LastRow)
but it doesn't work.

I would be most grateful if SKS would please furnish me
with the right expression.

And also, how would that expression change to find the
maximum of say the third column ?

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 176
Default Maximum of selection

Robin,

myMax = Application.WorksheetFunction.Max(Selection.Column s(1))

For the third column of the selection:

myMax = Application.WorksheetFunction.Max(Selection.Column s(3))

HTH,
Bernie


"Robin Clay" wrote in message
...
Greetings !

Having selected a block say 4 columns wide and 12 rows
long, I want to establish the maximum value of the
selected cells in a particular column.

I have tried
myMax = MAX( _
Selection.FirstCol & _
Selection.FirstRow & ":" & _
Selection.FirstCol & _
Selection.LastRow)
but it doesn't work.

I would be most grateful if SKS would please furnish me
with the right expression.

And also, how would that expression change to find the
maximum of say the third column ?



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
Limiting selection in a cell AND linking that selection to a list Lisa Excel Discussion (Misc queries) 1 July 28th 09 05:00 PM
Return Maximum from Column directly above Maximum in Row Code Numpty Charts and Charting in Excel 2 November 19th 08 07:29 AM
Copy Selection - Transpose Selection - Delete Selection Uninvisible Excel Discussion (Misc queries) 2 October 23rd 07 04:18 PM
Identifying a selection of a selection of a range swimfast Excel Worksheet Functions 1 March 1st 07 02:51 AM
limit cell list selection based on the selection of another list lorraine Excel Worksheet Functions 2 December 14th 04 08:17 PM


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

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"