PC Review


Reply
Thread Tools Rate Thread

Blocks a second cell to have a value if the first has one already

 
 
AA Arens
Guest
Posts: n/a
 
      23rd Jun 2007
In a range of cells (a row), I need a data validation that block a
second cell to be filled with a value. How to do that?

Sample:

A B C D
1 X

If Cell C1 has value X, another cell cannot have a velue, unless value
in C1 is deleted.

Bart
Excel 2003

 
Reply With Quote
 
 
 
 
Earl Kiosterud
Guest
Posts: n/a
 
      23rd Jun 2007
AA,

Presumably, your X is a variable -- the first cell can have any value, and a second cell
should be blocked. Data - Validation - Custom:

=COUNTIF($A$1:$D$1,"*")<2

--
Earl Kiosterud
www.smokeylake.com

Note: Top-posting has been the norm here.
Some folks prefer bottom-posting.
But if you bottom-post to a reply that's
already top-posted, the thread gets messy.
When in Rome...
-----------------------------------------------------------------------
"AA Arens" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> In a range of cells (a row), I need a data validation that block a
> second cell to be filled with a value. How to do that?
>
> Sample:
>
> A B C D
> 1 X
>
> If Cell C1 has value X, another cell cannot have a velue, unless value
> in C1 is deleted.
>
> Bart
> Excel 2003
>



 
Reply With Quote
 
AA Arens
Guest
Posts: n/a
 
      23rd Jun 2007
Hi earl,

I am still allowed to have another cell filled, so far this cell come
after (right of) the first cell.
Make it possible that only one cell can be filled in from a row-array.

With x I meaned only x can be filled in, no other value.

Thank you for your help.

Bart

\

Earl Kiosterud wrote:
> AA,
>
> Presumably, your X is a variable -- the first cell can have any value, and a second cell
> should be blocked. Data - Validation - Custom:
>
> =COUNTIF($A$1:$D$1,"*")<2
>
> --
> Earl Kiosterud
> www.smokeylake.com
>
> Note: Top-posting has been the norm here.
> Some folks prefer bottom-posting.
> But if you bottom-post to a reply that's
> already top-posted, the thread gets messy.
> When in Rome...
> -----------------------------------------------------------------------
> "AA Arens" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
> > In a range of cells (a row), I need a data validation that block a
> > second cell to be filled with a value. How to do that?
> >
> > Sample:
> >
> > A B C D
> > 1 X
> >
> > If Cell C1 has value X, another cell cannot have a velue, unless value
> > in C1 is deleted.
> >
> > Bart
> > Excel 2003
> >


 
Reply With Quote
 
Earl Kiosterud
Guest
Posts: n/a
 
      23rd Jun 2007
Bart,

Now you're saying that the cells must be filled left-to-right, starting with A1, and can
only be filled with "x". If that's the case, use this in the Data - Validation for cell A1:

=A1="x"

And use this in B11:

=AND(A1="x",B1="x")

Note that when you select B11, the active (white) cell of your selection must be B1. This
will allow either X or x. These will allow either x or X.
--
Earl Kiosterud
www.smokeylake.com

Note: Top-posting has been the norm here.
Some folks prefer bottom-posting.
But if you bottom-post to a reply that's
already top-posted, the thread gets messy.
When in Rome...
-----------------------------------------------------------------------
"AA Arens" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Hi earl,
>
> I am still allowed to have another cell filled, so far this cell come
> after (right of) the first cell.
> Make it possible that only one cell can be filled in from a row-array.
>
> With x I meaned only x can be filled in, no other value.
>
> Thank you for your help.
>
> Bart
>
> \
>
> Earl Kiosterud wrote:
>> AA,
>>
>> Presumably, your X is a variable -- the first cell can have any value, and a second cell
>> should be blocked. Data - Validation - Custom:
>>
>> =COUNTIF($A$1:$D$1,"*")<2
>>
>> --
>> Earl Kiosterud
>> www.smokeylake.com
>>
>> Note: Top-posting has been the norm here.
>> Some folks prefer bottom-posting.
>> But if you bottom-post to a reply that's
>> already top-posted, the thread gets messy.
>> When in Rome...
>> -----------------------------------------------------------------------
>> "AA Arens" <(E-Mail Removed)> wrote in message
>> news:(E-Mail Removed)...
>> > In a range of cells (a row), I need a data validation that block a
>> > second cell to be filled with a value. How to do that?
>> >
>> > Sample:
>> >
>> > A B C D
>> > 1 X
>> >
>> > If Cell C1 has value X, another cell cannot have a velue, unless value
>> > in C1 is deleted.
>> >
>> > Bart
>> > Excel 2003
>> >

>



 
Reply With Quote
 
AA Arens
Guest
Posts: n/a
 
      24th Jun 2007
Earl,

When I mentioned in my first posting is what I mean.

In a range of cells A1-E1 I am only allowed to fill one cell with x
(and only x or X).

Type from left to right: (X -> X etc.)
In your first solution, I was still able to fill another cell with x
if a cell left of the active cell has value x as well.

Typing from right to left: (X <- X etc.)
Your first solution worked, I could not fill in x if a cell right of
it has already value x


And: No other character should be allowed to be filled in at all.

Bart


Earl Kiosterud wrote:
> Bart,
>
> Now you're saying that the cells must be filled left-to-right, starting with A1, and can
> only be filled with "x". If that's the case, use this in the Data - Validation for cell A1:
>
> =A1="x"
>
> And use this in B11:
>
> =AND(A1="x",B1="x")
>
> Note that when you select B11, the active (white) cell of your selection must be B1. This
> will allow either X or x. These will allow either x or X.
> --
> Earl Kiosterud
> www.smokeylake.com
>
> Note: Top-posting has been the norm here.
> Some folks prefer bottom-posting.
> But if you bottom-post to a reply that's
> already top-posted, the thread gets messy.
> When in Rome...
> -----------------------------------------------------------------------
> "AA Arens" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
> > Hi earl,
> >
> > I am still allowed to have another cell filled, so far this cell come
> > after (right of) the first cell.
> > Make it possible that only one cell can be filled in from a row-array.
> >
> > With x I meaned only x can be filled in, no other value.
> >
> > Thank you for your help.
> >
> > Bart
> >
> > \
> >
> > Earl Kiosterud wrote:
> >> AA,
> >>
> >> Presumably, your X is a variable -- the first cell can have any value, and a second cell
> >> should be blocked. Data - Validation - Custom:
> >>
> >> =COUNTIF($A$1:$D$1,"*")<2
> >>
> >> --
> >> Earl Kiosterud
> >> www.smokeylake.com
> >>
> >> Note: Top-posting has been the norm here.
> >> Some folks prefer bottom-posting.
> >> But if you bottom-post to a reply that's
> >> already top-posted, the thread gets messy.
> >> When in Rome...
> >> -----------------------------------------------------------------------
> >> "AA Arens" <(E-Mail Removed)> wrote in message
> >> news:(E-Mail Removed)...
> >> > In a range of cells (a row), I need a data validation that block a
> >> > second cell to be filled with a value. How to do that?
> >> >
> >> > Sample:
> >> >
> >> > A B C D
> >> > 1 X
> >> >
> >> > If Cell C1 has value X, another cell cannot have a velue, unless value
> >> > in C1 is deleted.
> >> >
> >> > Bart
> >> > Excel 2003
> >> >

> >


 
Reply With Quote
 
T. Valko
Guest
Posts: n/a
 
      24th Jun 2007
>In a range of cells A1-E1 I am only allowed to fill one cell with x

Try this:

Select the range A1:E1
Goto Data>Validation
Allow: Custom
Formula: =AND(A1="x",COUNTIF($A1:$E1,"x")<2)
OK

I'm assuming you want to allow "x" or "X" and *nothing else*.

Biff

"AA Arens" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Earl,
>
> When I mentioned in my first posting is what I mean.
>
> In a range of cells A1-E1 I am only allowed to fill one cell with x
> (and only x or X).
>
> Type from left to right: (X -> X etc.)
> In your first solution, I was still able to fill another cell with x
> if a cell left of the active cell has value x as well.
>
> Typing from right to left: (X <- X etc.)
> Your first solution worked, I could not fill in x if a cell right of
> it has already value x
>
>
> And: No other character should be allowed to be filled in at all.
>
> Bart
>
>
> Earl Kiosterud wrote:
>> Bart,
>>
>> Now you're saying that the cells must be filled left-to-right, starting
>> with A1, and can
>> only be filled with "x". If that's the case, use this in the Data -
>> Validation for cell A1:
>>
>> =A1="x"
>>
>> And use this in B11:
>>
>> =AND(A1="x",B1="x")
>>
>> Note that when you select B11, the active (white) cell of your
>> selection must be B1. This
>> will allow either X or x. These will allow either x or X.
>> --
>> Earl Kiosterud
>> www.smokeylake.com
>>
>> Note: Top-posting has been the norm here.
>> Some folks prefer bottom-posting.
>> But if you bottom-post to a reply that's
>> already top-posted, the thread gets messy.
>> When in Rome...
>> -----------------------------------------------------------------------
>> "AA Arens" <(E-Mail Removed)> wrote in message
>> news:(E-Mail Removed)...
>> > Hi earl,
>> >
>> > I am still allowed to have another cell filled, so far this cell come
>> > after (right of) the first cell.
>> > Make it possible that only one cell can be filled in from a row-array.
>> >
>> > With x I meaned only x can be filled in, no other value.
>> >
>> > Thank you for your help.
>> >
>> > Bart
>> >
>> > \
>> >
>> > Earl Kiosterud wrote:
>> >> AA,
>> >>
>> >> Presumably, your X is a variable -- the first cell can have any value,
>> >> and a second cell
>> >> should be blocked. Data - Validation - Custom:
>> >>
>> >> =COUNTIF($A$1:$D$1,"*")<2
>> >>
>> >> --
>> >> Earl Kiosterud
>> >> www.smokeylake.com
>> >>
>> >> Note: Top-posting has been the norm here.
>> >> Some folks prefer bottom-posting.
>> >> But if you bottom-post to a reply that's
>> >> already top-posted, the thread gets messy.
>> >> When in Rome...
>> >> -----------------------------------------------------------------------
>> >> "AA Arens" <(E-Mail Removed)> wrote in message
>> >> news:(E-Mail Removed)...
>> >> > In a range of cells (a row), I need a data validation that block a
>> >> > second cell to be filled with a value. How to do that?
>> >> >
>> >> > Sample:
>> >> >
>> >> > A B C D
>> >> > 1 X
>> >> >
>> >> > If Cell C1 has value X, another cell cannot have a velue, unless
>> >> > value
>> >> > in C1 is deleted.
>> >> >
>> >> > Bart
>> >> > Excel 2003
>> >> >
>> >

>



 
Reply With Quote
 
AA Arens
Guest
Posts: n/a
 
      24th Jun 2007
Hi Biff,

Works partly. I am not allowed to add one to the left of the cell with
value x, but I am still able to add one to the right one cell with
value x.

Same result as the offer from Earl.

Bart

On Jun 24, 10:11 am, "T. Valko" <biffinp...@comcast.net> wrote:
> >In a range of cells A1-E1 I am only allowed to fill one cell with x

>
> Try this:
>
> Select the range A1:E1
> Goto Data>Validation
> Allow: Custom
> Formula: =AND(A1="x",COUNTIF($A1:$E1,"x")<2)
> OK
>
> I'm assuming you want to allow "x" or "X" and *nothing else*.
>
> Biff
>
> "AA Arens" <bartvandon...@gmail.com> wrote in message
>
> news:(E-Mail Removed)...
>
> > Earl,

>
> > When I mentioned in my first posting is what I mean.

>
> > In a range of cells A1-E1 I am only allowed to fill one cell with x
> > (and only x or X).

>
> > Type from left to right: (X -> X etc.)
> > In your first solution, I was still able to fill another cell with x
> > if a cell left of the active cell has value x as well.

>
> > Typing from right to left: (X <- X etc.)
> > Your first solution worked, I could not fill in x if a cell right of
> > it has already value x

>
> > And: No other character should be allowed to be filled in at all.

>
> > Bart

>
> > Earl Kiosterud wrote:
> >> Bart,

>
> >> Now you're saying that the cells must be filled left-to-right, starting
> >> with A1, and can
> >> only be filled with "x". If that's the case, use this in the Data -
> >> Validation for cell A1:

>
> >> =A1="x"

>
> >> And use this in B11:

>
> >> =AND(A1="x",B1="x")

>
> >> Note that when you select B11, the active (white) cell of your
> >> selection must be B1. This
> >> will allow either X or x. These will allow either x or X.
> >> --
> >> Earl Kiosterud
> >>www.smokeylake.com

>
> >> Note: Top-posting has been the norm here.
> >> Some folks prefer bottom-posting.
> >> But if you bottom-post to a reply that's
> >> already top-posted, the thread gets messy.
> >> When in Rome...
> >> -----------------------------------------------------------------------
> >> "AA Arens" <bartvandon...@gmail.com> wrote in message
> >>news:(E-Mail Removed)...
> >> > Hi earl,

>
> >> > I am still allowed to have another cell filled, so far this cell come
> >> > after (right of) the first cell.
> >> > Make it possible that only one cell can be filled in from a row-array.

>
> >> > With x I meaned only x can be filled in, no other value.

>
> >> > Thank you for your help.

>
> >> > Bart

>
> >> > \

>
> >> > Earl Kiosterud wrote:
> >> >> AA,

>
> >> >> Presumably, your X is a variable -- the first cell can have any value,
> >> >> and a second cell
> >> >> should be blocked. Data - Validation - Custom:

>
> >> >> =COUNTIF($A$1:$D$1,"*")<2

>
> >> >> --
> >> >> Earl Kiosterud
> >> >>www.smokeylake.com

>
> >> >> Note: Top-posting has been the norm here.
> >> >> Some folks prefer bottom-posting.
> >> >> But if you bottom-post to a reply that's
> >> >> already top-posted, the thread gets messy.
> >> >> When in Rome...
> >> >> -----------------------------------------------------------------------
> >> >> "AA Arens" <bartvandon...@gmail.com> wrote in message
> >> >>news:(E-Mail Removed)...
> >> >> > In a range of cells (a row), I need a data validation that block a
> >> >> > second cell to be filled with a value. How to do that?

>
> >> >> > Sample:

>
> >> >> > A B C D
> >> >> > 1 X

>
> >> >> > If Cell C1 has value X, another cell cannot have a velue, unless
> >> >> > value
> >> >> > in C1 is deleted.

>
> >> >> > Bart
> >> >> > Excel 2003



 
Reply With Quote
 
Earl Kiosterud
Guest
Posts: n/a
 
      24th Jun 2007
Bart,

You need to describe the problem more accurately. We can't determine if what you're saying
is what you want, or what is happening that you DON'T want. We're not struggling with a
solution -- we're struggling to understand the problem.
--
Earl Kiosterud
www.smokeylake.com

Note: Top-posting has been the norm here.
Some folks prefer bottom-posting.
But if you bottom-post to a reply that's
already top-posted, the thread gets messy.
When in Rome...
-----------------------------------------------------------------------
"AA Arens" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Hi Biff,
>
> Works partly. I am not allowed to add one to the left of the cell with
> value x, but I am still able to add one to the right one cell with
> value x.
>
> Same result as the offer from Earl.
>
> Bart
>
> On Jun 24, 10:11 am, "T. Valko" <biffinp...@comcast.net> wrote:
>> >In a range of cells A1-E1 I am only allowed to fill one cell with x

>>
>> Try this:
>>
>> Select the range A1:E1
>> Goto Data>Validation
>> Allow: Custom
>> Formula: =AND(A1="x",COUNTIF($A1:$E1,"x")<2)
>> OK
>>
>> I'm assuming you want to allow "x" or "X" and *nothing else*.
>>
>> Biff
>>
>> "AA Arens" <bartvandon...@gmail.com> wrote in message
>>
>> news:(E-Mail Removed)...
>>
>> > Earl,

>>
>> > When I mentioned in my first posting is what I mean.

>>
>> > In a range of cells A1-E1 I am only allowed to fill one cell with x
>> > (and only x or X).

>>
>> > Type from left to right: (X -> X etc.)
>> > In your first solution, I was still able to fill another cell with x
>> > if a cell left of the active cell has value x as well.

>>
>> > Typing from right to left: (X <- X etc.)
>> > Your first solution worked, I could not fill in x if a cell right of
>> > it has already value x

>>
>> > And: No other character should be allowed to be filled in at all.

>>
>> > Bart

>>
>> > Earl Kiosterud wrote:
>> >> Bart,

>>
>> >> Now you're saying that the cells must be filled left-to-right, starting
>> >> with A1, and can
>> >> only be filled with "x". If that's the case, use this in the Data -
>> >> Validation for cell A1:

>>
>> >> =A1="x"

>>
>> >> And use this in B11:

>>
>> >> =AND(A1="x",B1="x")

>>
>> >> Note that when you select B11, the active (white) cell of your
>> >> selection must be B1. This
>> >> will allow either X or x. These will allow either x or X.
>> >> --
>> >> Earl Kiosterud
>> >>www.smokeylake.com

>>
>> >> Note: Top-posting has been the norm here.
>> >> Some folks prefer bottom-posting.
>> >> But if you bottom-post to a reply that's
>> >> already top-posted, the thread gets messy.
>> >> When in Rome...
>> >> -----------------------------------------------------------------------
>> >> "AA Arens" <bartvandon...@gmail.com> wrote in message
>> >>news:(E-Mail Removed)...
>> >> > Hi earl,

>>
>> >> > I am still allowed to have another cell filled, so far this cell come
>> >> > after (right of) the first cell.
>> >> > Make it possible that only one cell can be filled in from a row-array.

>>
>> >> > With x I meaned only x can be filled in, no other value.

>>
>> >> > Thank you for your help.

>>
>> >> > Bart

>>
>> >> > \

>>
>> >> > Earl Kiosterud wrote:
>> >> >> AA,

>>
>> >> >> Presumably, your X is a variable -- the first cell can have any value,
>> >> >> and a second cell
>> >> >> should be blocked. Data - Validation - Custom:

>>
>> >> >> =COUNTIF($A$1:$D$1,"*")<2

>>
>> >> >> --
>> >> >> Earl Kiosterud
>> >> >>www.smokeylake.com

>>
>> >> >> Note: Top-posting has been the norm here.
>> >> >> Some folks prefer bottom-posting.
>> >> >> But if you bottom-post to a reply that's
>> >> >> already top-posted, the thread gets messy.
>> >> >> When in Rome...
>> >> >> -----------------------------------------------------------------------
>> >> >> "AA Arens" <bartvandon...@gmail.com> wrote in message
>> >> >>news:(E-Mail Removed)...
>> >> >> > In a range of cells (a row), I need a data validation that block a
>> >> >> > second cell to be filled with a value. How to do that?

>>
>> >> >> > Sample:

>>
>> >> >> > A B C D
>> >> >> > 1 X

>>
>> >> >> > If Cell C1 has value X, another cell cannot have a velue, unless
>> >> >> > value
>> >> >> > in C1 is deleted.

>>
>> >> >> > Bart
>> >> >> > Excel 2003

>
>



 
Reply With Quote
 
T. Valko
Guest
Posts: n/a
 
      24th Jun 2007
I think I may understand what they want.

Assume the range is A1:E1

If they enter X in A1 then allow only one other X in B1:E1
If they enter X in B1 then allow only one other X in C1:E1 and do not allow
X in A1

Once the first X is entered don't allow another X to the left of that first
X.

I don't think it can be done *exactly* the way they want but you can
restrict X to no more than 2 cells in the range:

=AND(OR(A1="",A1="x"),COUNTIF($A1:$E1,"x")<=2)

Biff

"Earl Kiosterud" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Bart,
>
> You need to describe the problem more accurately. We can't determine if
> what you're saying is what you want, or what is happening that you DON'T
> want. We're not struggling with a solution -- we're struggling to
> understand the problem.
> --
> Earl Kiosterud
> www.smokeylake.com
>
> Note: Top-posting has been the norm here.
> Some folks prefer bottom-posting.
> But if you bottom-post to a reply that's
> already top-posted, the thread gets messy.
> When in Rome...
> -----------------------------------------------------------------------
> "AA Arens" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
>> Hi Biff,
>>
>> Works partly. I am not allowed to add one to the left of the cell with
>> value x, but I am still able to add one to the right one cell with
>> value x.
>>
>> Same result as the offer from Earl.
>>
>> Bart
>>
>> On Jun 24, 10:11 am, "T. Valko" <biffinp...@comcast.net> wrote:
>>> >In a range of cells A1-E1 I am only allowed to fill one cell with x
>>>
>>> Try this:
>>>
>>> Select the range A1:E1
>>> Goto Data>Validation
>>> Allow: Custom
>>> Formula: =AND(A1="x",COUNTIF($A1:$E1,"x")<2)
>>> OK
>>>
>>> I'm assuming you want to allow "x" or "X" and *nothing else*.
>>>
>>> Biff
>>>
>>> "AA Arens" <bartvandon...@gmail.com> wrote in message
>>>
>>> news:(E-Mail Removed)...
>>>
>>> > Earl,
>>>
>>> > When I mentioned in my first posting is what I mean.
>>>
>>> > In a range of cells A1-E1 I am only allowed to fill one cell with x
>>> > (and only x or X).
>>>
>>> > Type from left to right: (X -> X etc.)
>>> > In your first solution, I was still able to fill another cell with x
>>> > if a cell left of the active cell has value x as well.
>>>
>>> > Typing from right to left: (X <- X etc.)
>>> > Your first solution worked, I could not fill in x if a cell right of
>>> > it has already value x
>>>
>>> > And: No other character should be allowed to be filled in at all.
>>>
>>> > Bart
>>>
>>> > Earl Kiosterud wrote:
>>> >> Bart,
>>>
>>> >> Now you're saying that the cells must be filled left-to-right,
>>> >> starting
>>> >> with A1, and can
>>> >> only be filled with "x". If that's the case, use this in the Data -
>>> >> Validation for cell A1:
>>>
>>> >> =A1="x"
>>>
>>> >> And use this in B11:
>>>
>>> >> =AND(A1="x",B1="x")
>>>
>>> >> Note that when you select B11, the active (white) cell of your
>>> >> selection must be B1. This
>>> >> will allow either X or x. These will allow either x or X.
>>> >> --
>>> >> Earl Kiosterud
>>> >>www.smokeylake.com
>>>
>>> >> Note: Top-posting has been the norm here.
>>> >> Some folks prefer bottom-posting.
>>> >> But if you bottom-post to a reply that's
>>> >> already top-posted, the thread gets messy.
>>> >> When in Rome...
>>> >> -----------------------------------------------------------------------
>>> >> "AA Arens" <bartvandon...@gmail.com> wrote in message
>>> >>news:(E-Mail Removed)...
>>> >> > Hi earl,
>>>
>>> >> > I am still allowed to have another cell filled, so far this cell
>>> >> > come
>>> >> > after (right of) the first cell.
>>> >> > Make it possible that only one cell can be filled in from a
>>> >> > row-array.
>>>
>>> >> > With x I meaned only x can be filled in, no other value.
>>>
>>> >> > Thank you for your help.
>>>
>>> >> > Bart
>>>
>>> >> > \
>>>
>>> >> > Earl Kiosterud wrote:
>>> >> >> AA,
>>>
>>> >> >> Presumably, your X is a variable -- the first cell can have any
>>> >> >> value,
>>> >> >> and a second cell
>>> >> >> should be blocked. Data - Validation - Custom:
>>>
>>> >> >> =COUNTIF($A$1:$D$1,"*")<2
>>>
>>> >> >> --
>>> >> >> Earl Kiosterud
>>> >> >>www.smokeylake.com
>>>
>>> >> >> Note: Top-posting has been the norm here.
>>> >> >> Some folks prefer bottom-posting.
>>> >> >> But if you bottom-post to a reply that's
>>> >> >> already top-posted, the thread gets messy.
>>> >> >> When in Rome...
>>> >> >> -----------------------------------------------------------------------
>>> >> >> "AA Arens" <bartvandon...@gmail.com> wrote in message
>>> >> >>news:(E-Mail Removed)...
>>> >> >> > In a range of cells (a row), I need a data validation that block
>>> >> >> > a
>>> >> >> > second cell to be filled with a value. How to do that?
>>>
>>> >> >> > Sample:
>>>
>>> >> >> > A B C D
>>> >> >> > 1 X
>>>
>>> >> >> > If Cell C1 has value X, another cell cannot have a velue, unless
>>> >> >> > value
>>> >> >> > in C1 is deleted.
>>>
>>> >> >> > Bart
>>> >> >> > Excel 2003

>>
>>

>
>



 
Reply With Quote
 
AA Arens
Guest
Posts: n/a
 
      25th Jun 2007
Hi All,

I thought I was clear enough, but will explain again.

I have a range of cells A1-E1
I am only allowed to fill one of these cells with "x". If i try to
fill another cell with x, then I get the message (from data
validation): "Only value x is allowed or another cell has already a
value x. Clear the other cell first". And..., only value x is allowed,
so not other value, even when all cells are still empty.

So:
Allowed
ABCDE
x
x
x

Not allowed
ABCDE
y
x x
x z


Bart




On Jun 25, 1:03 am, "T. Valko" <biffinp...@comcast.net> wrote:
> I think I may understand what they want.
>
> Assume the range is A1:E1
>
> If they enter X in A1 then allow only one other X in B1:E1
> If they enter X in B1 then allow only one other X in C1:E1 and do not allow
> X in A1
>
> Once the first X is entered don't allow another X to the left of that first
> X.
>
> I don't think it can be done *exactly* the way they want but you can
> restrict X to no more than 2 cells in the range:
>
> =AND(OR(A1="",A1="x"),COUNTIF($A1:$E1,"x")<=2)
>
> Biff
>
> "Earl Kiosterud" <some...@nowhere.com> wrote in message
>
> news:(E-Mail Removed)...
>
> > Bart,

>
> > You need to describe the problem more accurately. We can't determine if
> > what you're saying is what you want, or what is happening that you DON'T
> > want. We're not struggling with a solution -- we're struggling to
> > understand the problem.
> > --
> > Earl Kiosterud
> >www.smokeylake.com

>
> > Note: Top-posting has been the norm here.
> > Some folks prefer bottom-posting.
> > But if you bottom-post to a reply that's
> > already top-posted, the thread gets messy.
> > When in Rome...
> > -----------------------------------------------------------------------
> > "AAArens" <bartvandon...@gmail.com> wrote in message
> >news:(E-Mail Removed)...
> >> Hi Biff,

>
> >> Works partly. I am not allowed to add one to the left of the cell with
> >> value x, but I am still able to add one to the right one cell with
> >> value x.

>
> >> Same result as the offer from Earl.

>
> >> Bart

>
> >> On Jun 24, 10:11 am, "T. Valko" <biffinp...@comcast.net> wrote:
> >>> >In a range of cells A1-E1 I am only allowed to fill one cell with x

>
> >>> Try this:

>
> >>> Select the range A1:E1
> >>> Goto Data>Validation
> >>> Allow: Custom
> >>> Formula: =AND(A1="x",COUNTIF($A1:$E1,"x")<2)
> >>> OK

>
> >>> I'm assuming you want to allow "x" or "X" and *nothing else*.

>
> >>> Biff

>
> >>> "AAArens" <bartvandon...@gmail.com> wrote in message

>
> >>>news:(E-Mail Removed)...

>
> >>> > Earl,

>
> >>> > When I mentioned in my first posting is what I mean.

>
> >>> > In a range of cells A1-E1 I am only allowed to fill one cell with x
> >>> > (and only x or X).

>
> >>> > Type from left to right: (X -> X etc.)
> >>> > In your first solution, I was still able to fill another cell with x
> >>> > if a cell left of the active cell has value x as well.

>
> >>> > Typing from right to left: (X <- X etc.)
> >>> > Your first solution worked, I could not fill in x if a cell right of
> >>> > it has already value x

>
> >>> > And: No other character should be allowed to be filled in at all.

>
> >>> > Bart

>
> >>> > Earl Kiosterud wrote:
> >>> >> Bart,

>
> >>> >> Now you're saying that the cells must be filled left-to-right,
> >>> >> starting
> >>> >> with A1, and can
> >>> >> only be filled with "x". If that's the case, use this in the Data -
> >>> >> Validation for cell A1:

>
> >>> >> =A1="x"

>
> >>> >> And use this in B11:

>
> >>> >> =AND(A1="x",B1="x")

>
> >>> >> Note that when you select B11, the active (white) cell of your
> >>> >> selection must be B1. This
> >>> >> will allow either X or x. These will allow either x or X.
> >>> >> --
> >>> >> Earl Kiosterud
> >>> >>www.smokeylake.com

>
> >>> >> Note: Top-posting has been the norm here.
> >>> >> Some folks prefer bottom-posting.
> >>> >> But if you bottom-post to a reply that's
> >>> >> already top-posted, the thread gets messy.
> >>> >> When in Rome...
> >>> >> -----------------------------------------------------------------------
> >>> >> "AAArens" <bartvandon...@gmail.com> wrote in message
> >>> >>news:(E-Mail Removed)...
> >>> >> > Hi earl,

>
> >>> >> > I am still allowed to have another cell filled, so far this cell
> >>> >> > come
> >>> >> > after (right of) the first cell.
> >>> >> > Make it possible that only one cell can be filled in from a
> >>> >> > row-array.

>
> >>> >> > With x I meaned only x can be filled in, no other value.

>
> >>> >> > Thank you for your help.

>
> >>> >> > Bart

>
> >>> >> > \

>
> >>> >> > Earl Kiosterud wrote:
> >>> >> >>AA,

>
> >>> >> >> Presumably, your X is a variable -- the first cell can have any
> >>> >> >> value,
> >>> >> >> and a second cell
> >>> >> >> should be blocked. Data - Validation - Custom:

>
> >>> >> >> =COUNTIF($A$1:$D$1,"*")<2

>
> >>> >> >> --
> >>> >> >> Earl Kiosterud
> >>> >> >>www.smokeylake.com

>
> >>> >> >> Note: Top-posting has been the norm here.
> >>> >> >> Some folks prefer bottom-posting.
> >>> >> >> But if you bottom-post to a reply that's
> >>> >> >> already top-posted, the thread gets messy.
> >>> >> >> When in Rome...
> >>> >> >> -----------------------------------------------------------------------
> >>> >> >> "AAArens" <bartvandon...@gmail.com> wrote in message
> >>> >> >>news:(E-Mail Removed)...
> >>> >> >> > In a range of cells (a row), I need a data validation that block
> >>> >> >> > a
> >>> >> >> > second cell to be filled with a value. How to do that?

>
> >>> >> >> > Sample:

>
> >>> >> >> > A B C D
> >>> >> >> > 1 X

>
> >>> >> >> > If Cell C1 has value X, another cell cannot have a velue, unless
> >>> >> >> > value
> >>> >> >> > in C1 is deleted.

>
> >>> >> >> > Bart
> >>> >> >> > Excel 2003







 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
In Excel, how do I print the cell blocks as well as the data? aa3kt Microsoft Excel Misc 2 29th Apr 2010 05:23 PM
Building Blocks: Can the blocks of text be shared with other users SaraC Microsoft Word New Users 1 15th Dec 2009 10:23 PM
How can I show/hide the cell comment blocks ? raymond Microsoft Excel New Users 1 19th Jun 2009 05:47 PM
getting cell color to allow alternating blocks of like value == likecolor cells jrg167@gmail.com Microsoft Excel Discussion 4 21st Dec 2008 10:50 PM
Coloring Cell Blocks Troy Microsoft Excel Worksheet Functions 5 10th Oct 2003 03:06 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 12:00 PM.