Thread: basic opertors
View Single Post
  #11   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Héctor Miguel Héctor Miguel is offline
external usenet poster
 
Posts: 434
Default basic opertors

Tanya, I'm glad to be in help (and thanks to you, for posting-back)

regards,
hector.

... it worked this time, I understood all except step 3 the first time.
I have named cells/ranges before but didn't realise you could use a formula in the 'Refers to...'
This is much like writing a function and calling it... A very interesting lesson! Thank you again.
Regards
Tanya


(sniped from previous posts)...
I am by no means a power user of VBA but I do have some understanding of it.
However, having said that your xl-4 macro language makes no sense to me what so ever.
You solution is written like a formula? Please be more explicit
I would like to be able to understand what you are trying to communicate.


just follow this steps:

- use [A1] as the "container" of your "operator" (one single-sign per time: +, -, *, /, ^, ...)
(the named-formua in step 3 will use this reference in an absolute-row&column notation)
if necessary, preceed the divisor / (when been the operator) with an apostrophe or a space

1) fill [B2:F2] with: 1,2,3,4,5
(the named-formua in step 3 will use this reference in an absolute-row notation)

2) fill [A3:A7] with: 1,2,3,4,5
(the named-formua in step 3 will use this reference in an absolute-column notation)

3) select [B3] (it is importan to be the activecell when)...
do a (menu) insert / name / define...
name: Bas.Op
formula: =evaluate(!$a3&!$a$1&!b$2)+0*now()

- note the "!" sign preceeding every cell-reference
and the last part "...+0*now()" is to make it "volatile" with re/calculations of the model/sheet/workbook

4) in cell [B3] "call" the name used in step 3 and {enter} (i.e. =bas.op)

5) fill [B3:F7] the same as B3 (i.e. =bas.op) and/or copy/drag/...

the note regarding xl-2002 as a minimum requirement is due to (under certain circumstances)
previous versions might *crash* with some xl-4 macro-functions while used as this proposal