A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » New Users
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

IF logic formula



 
 
Thread Tools Display Modes
  #1  
Old February 24th, 2009, 03:25 PM posted to microsoft.public.excel.newusers
rwfster
external usenet poster
 
Posts: 11
Default IF logic formula

Is there a formula that would allow the following: the entry of 6 variables
(a, b, c, , 1, 2, 3) into cells A1 through A6 as either single entries
(a..b..c..etc) or multiple entries with a maximum of 3 variables
(ab..ac3..etc) that will result in an "X" inserted into cell A12

--
rwfster
  #2  
Old February 24th, 2009, 03:35 PM posted to microsoft.public.excel.newusers
Bob Phillips[_2_]
external usenet poster
 
Posts: 1,562
Default IF logic formula

No, a formula only returns a result to its parent cell.

--
__________________________________
HTH

Bob

"rwfster" wrote in message
news
Is there a formula that would allow the following: the entry of 6
variables
(a, b, c, , 1, 2, 3) into cells A1 through A6 as either single entries
(a..b..c..etc) or multiple entries with a maximum of 3 variables
(ab..ac3..etc) that will result in an "X" inserted into cell A12

--
rwfster



  #3  
Old February 25th, 2009, 12:04 AM posted to microsoft.public.excel.newusers
joeu2004
external usenet poster
 
Posts: 1,748
Default IF logic formula

On Feb 24, 7:25*am, rwfster wrote:
Is there a formula that would allow the following:
*the entry of 6 variables (a, b, c, , 1, 2, 3) into
cells A1 through A6 as either single entries
(a..b..c..etc) or multiple entries with a maximum
of 3 variables (ab..ac3..etc) that will result in
an "X" inserted into cell A12


Your requirement is unclear to me. But perhaps the following paradigm
will lead you to a usable solution.

Suppose you have the following VBA function:

Function foobar(Optional flag)
If IsMissing(flag) Then
foobar = Array("a", "b", "c", "1", "2", "3")
Else
foobar = Array("ab", "c1", "23", "X", "X", "X")
End If
End Function

Then if you select 6 cells in a row, you can enter the following array
formula (commit with ctrl-shift-Enter, not simply Enter):

=foobar()

or

=foobar(1)

Note: If you would like FOOBAR to return a column of cells, use
Application.Transpose(Array(...)). Or simply call =transpose(foobar
()), again as an array formula.
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


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


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