![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
New Member
Join Date: Mar 2002
Posts: 3
|
I want to filter by font colour and MSKB Q213923 suggests defining a name with the formula GET.CELL(24,OFFSET(INDIRECT("A2"),ROW()-2,0)).
I want to understand how the formula is constructed, what it all means, so I can use it for different things. What's it all about?? |
|
|
|
|
|
#2 | |
|
MrExcel MVP
Join Date: Feb 2002
Location: Austin, Texas USA
Posts: 11,654
|
Quote:
[ This Message was edited by: Mark W. on 2002-03-13 15:02 ] |
|
|
|
|
|
|
#3 |
|
Join Date: Mar 2002
Posts: 33
|
The GET.CELL function is part of the Excel4 Macro language (which was VBA's predecessor).
It cannot be used directly in a worksheet cell. The syntax is :- GET.CELL(type_num, reference) Type_num 24 returns the font color of the first character in the reference, as a number in the range 1 to 56. If the font color is set to automatic, it returns 0. I will assume you are familiar with the OFFSET, INDIRECT & ROW functions, so :- INDIRECT("A2") fixes the reference as cell A2. ROW()-2 provides the number of rows to be offset from A2. So in row 2 the offset is 0, in row 3 it is 1, etc. Post again if not clear. |
|
|
|
|
|
#4 |
|
New Member
Join Date: Mar 2002
Posts: 3
|
Thank you to both Mark W. and Arviragus for you feedback. I would however appreciate some clarification of certain points.
My understanding (in plain english) of the GET.CELL(24,OFFSET(INDIRECT("A2"),ROW()-2,0)) function is: "get the font colour format of the first character in the cell which is offset from cell A2. The degree of row offset equals the row number of the current row minus 2. The column offset is zero" 1.How can I make this a general formula which is not dependant on cell A2? 2.Why does GET.CELL work in a defined name and not as a worksheet formula? 3.On what grounds can a formula be used in a defined name? (I have never used a formula as a defined name and I cannot visualize how it works) 4.I have downloaded macrofun.hlp - it seems to contain several useful looking functions. Why are these not available in Excel 2000? 5.If these functions work in defined names, why are they not supported in Excel help - this seems disempowering to the user? I look forward to hearing your reply Regards Lucy _________________ [ This Message was edited by: Robbinsl on 2002-03-14 01:08 ] |
|
|
|
|
|
#5 | |
|
Join Date: Mar 2002
Posts: 33
|
See comments below >>>
Quote:
|
|
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|