Changing the value of a cell in excel based on results in a range
I'm trying to automatize the result of a cell based on the color or data from a range.
Explanation: It will be a "OK" or "NOT OK" in a cell when there are red cells in a range or when there are some words there. Down is the image about an example of the table I want to work with.
Example
I want to know if it is possible to do it only with formula or have to do it through VBA.
excel
add a comment |
I'm trying to automatize the result of a cell based on the color or data from a range.
Explanation: It will be a "OK" or "NOT OK" in a cell when there are red cells in a range or when there are some words there. Down is the image about an example of the table I want to work with.
Example
I want to know if it is possible to do it only with formula or have to do it through VBA.
excel
It sounds like it could be solved with a formula combined with conditional formatting but what have you tried?
– Wayne Phipps
Nov 23 '18 at 8:31
I have the impression that the colour is based on the value of the cells, and now you want to base yourself on the colour in order to do something. Wouldn't it be better to base yourself of the values too?
– Dominique
Nov 23 '18 at 9:06
@Wayne, I tried to use IF combined with OR and COUNTIF, using the values to modify OK or NOT OK..
– Lohengrin Perez
Nov 23 '18 at 13:04
@Dominique, Yep, I moved to that after, because I though maybe colours will be more simple to do.
– Lohengrin Perez
Nov 23 '18 at 13:04
add a comment |
I'm trying to automatize the result of a cell based on the color or data from a range.
Explanation: It will be a "OK" or "NOT OK" in a cell when there are red cells in a range or when there are some words there. Down is the image about an example of the table I want to work with.
Example
I want to know if it is possible to do it only with formula or have to do it through VBA.
excel
I'm trying to automatize the result of a cell based on the color or data from a range.
Explanation: It will be a "OK" or "NOT OK" in a cell when there are red cells in a range or when there are some words there. Down is the image about an example of the table I want to work with.
Example
I want to know if it is possible to do it only with formula or have to do it through VBA.
excel
excel
asked Nov 23 '18 at 8:23
Lohengrin PerezLohengrin Perez
32
32
It sounds like it could be solved with a formula combined with conditional formatting but what have you tried?
– Wayne Phipps
Nov 23 '18 at 8:31
I have the impression that the colour is based on the value of the cells, and now you want to base yourself on the colour in order to do something. Wouldn't it be better to base yourself of the values too?
– Dominique
Nov 23 '18 at 9:06
@Wayne, I tried to use IF combined with OR and COUNTIF, using the values to modify OK or NOT OK..
– Lohengrin Perez
Nov 23 '18 at 13:04
@Dominique, Yep, I moved to that after, because I though maybe colours will be more simple to do.
– Lohengrin Perez
Nov 23 '18 at 13:04
add a comment |
It sounds like it could be solved with a formula combined with conditional formatting but what have you tried?
– Wayne Phipps
Nov 23 '18 at 8:31
I have the impression that the colour is based on the value of the cells, and now you want to base yourself on the colour in order to do something. Wouldn't it be better to base yourself of the values too?
– Dominique
Nov 23 '18 at 9:06
@Wayne, I tried to use IF combined with OR and COUNTIF, using the values to modify OK or NOT OK..
– Lohengrin Perez
Nov 23 '18 at 13:04
@Dominique, Yep, I moved to that after, because I though maybe colours will be more simple to do.
– Lohengrin Perez
Nov 23 '18 at 13:04
It sounds like it could be solved with a formula combined with conditional formatting but what have you tried?
– Wayne Phipps
Nov 23 '18 at 8:31
It sounds like it could be solved with a formula combined with conditional formatting but what have you tried?
– Wayne Phipps
Nov 23 '18 at 8:31
I have the impression that the colour is based on the value of the cells, and now you want to base yourself on the colour in order to do something. Wouldn't it be better to base yourself of the values too?
– Dominique
Nov 23 '18 at 9:06
I have the impression that the colour is based on the value of the cells, and now you want to base yourself on the colour in order to do something. Wouldn't it be better to base yourself of the values too?
– Dominique
Nov 23 '18 at 9:06
@Wayne, I tried to use IF combined with OR and COUNTIF, using the values to modify OK or NOT OK..
– Lohengrin Perez
Nov 23 '18 at 13:04
@Wayne, I tried to use IF combined with OR and COUNTIF, using the values to modify OK or NOT OK..
– Lohengrin Perez
Nov 23 '18 at 13:04
@Dominique, Yep, I moved to that after, because I though maybe colours will be more simple to do.
– Lohengrin Perez
Nov 23 '18 at 13:04
@Dominique, Yep, I moved to that after, because I though maybe colours will be more simple to do.
– Lohengrin Perez
Nov 23 '18 at 13:04
add a comment |
1 Answer
1
active
oldest
votes
If you need to use the color you will have to use vba, you can check the color of a cell with Cell.Interior.Color
On a side note, if you do not want to use vba you could use the condition you use for your conditional formatting (Assigning the color to the cell) in the cell formula instead of using the color.
I can use the data in the cells to determine if OK or NOT OK, kinda the if the value in this range or the value in this range is not "missing" then it is OK, but seems I'm struggling to manage to get the "if any of the cells in the range is not A" part. I want to avoid VBA because basically I'm not good in VBA, and maybe it will generate even more questions (I know my weakness)
– Lohengrin Perez
Nov 23 '18 at 8:39
If you need all the cells in an area to be "ok" you can use multiple conditions tied by AND with the different cells. If you need at least one cell in the area to be "ok" you can use OR instead, or any other combination of logic that will suit your needs
– Wolfaloo
Nov 23 '18 at 8:42
That one sounds more closer to what I want. Thanks for taking your time answering me, appreciate it.
– Lohengrin Perez
Nov 23 '18 at 8:47
No worries, in case this is not enough edit the question with your newfound issues and perhaps an example of your code
– Wolfaloo
Nov 23 '18 at 8:56
1
Sorry, my first question here (totally newbie). Done.
– Lohengrin Perez
Nov 23 '18 at 11:27
|
show 2 more comments
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53442971%2fchanging-the-value-of-a-cell-in-excel-based-on-results-in-a-range%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
If you need to use the color you will have to use vba, you can check the color of a cell with Cell.Interior.Color
On a side note, if you do not want to use vba you could use the condition you use for your conditional formatting (Assigning the color to the cell) in the cell formula instead of using the color.
I can use the data in the cells to determine if OK or NOT OK, kinda the if the value in this range or the value in this range is not "missing" then it is OK, but seems I'm struggling to manage to get the "if any of the cells in the range is not A" part. I want to avoid VBA because basically I'm not good in VBA, and maybe it will generate even more questions (I know my weakness)
– Lohengrin Perez
Nov 23 '18 at 8:39
If you need all the cells in an area to be "ok" you can use multiple conditions tied by AND with the different cells. If you need at least one cell in the area to be "ok" you can use OR instead, or any other combination of logic that will suit your needs
– Wolfaloo
Nov 23 '18 at 8:42
That one sounds more closer to what I want. Thanks for taking your time answering me, appreciate it.
– Lohengrin Perez
Nov 23 '18 at 8:47
No worries, in case this is not enough edit the question with your newfound issues and perhaps an example of your code
– Wolfaloo
Nov 23 '18 at 8:56
1
Sorry, my first question here (totally newbie). Done.
– Lohengrin Perez
Nov 23 '18 at 11:27
|
show 2 more comments
If you need to use the color you will have to use vba, you can check the color of a cell with Cell.Interior.Color
On a side note, if you do not want to use vba you could use the condition you use for your conditional formatting (Assigning the color to the cell) in the cell formula instead of using the color.
I can use the data in the cells to determine if OK or NOT OK, kinda the if the value in this range or the value in this range is not "missing" then it is OK, but seems I'm struggling to manage to get the "if any of the cells in the range is not A" part. I want to avoid VBA because basically I'm not good in VBA, and maybe it will generate even more questions (I know my weakness)
– Lohengrin Perez
Nov 23 '18 at 8:39
If you need all the cells in an area to be "ok" you can use multiple conditions tied by AND with the different cells. If you need at least one cell in the area to be "ok" you can use OR instead, or any other combination of logic that will suit your needs
– Wolfaloo
Nov 23 '18 at 8:42
That one sounds more closer to what I want. Thanks for taking your time answering me, appreciate it.
– Lohengrin Perez
Nov 23 '18 at 8:47
No worries, in case this is not enough edit the question with your newfound issues and perhaps an example of your code
– Wolfaloo
Nov 23 '18 at 8:56
1
Sorry, my first question here (totally newbie). Done.
– Lohengrin Perez
Nov 23 '18 at 11:27
|
show 2 more comments
If you need to use the color you will have to use vba, you can check the color of a cell with Cell.Interior.Color
On a side note, if you do not want to use vba you could use the condition you use for your conditional formatting (Assigning the color to the cell) in the cell formula instead of using the color.
If you need to use the color you will have to use vba, you can check the color of a cell with Cell.Interior.Color
On a side note, if you do not want to use vba you could use the condition you use for your conditional formatting (Assigning the color to the cell) in the cell formula instead of using the color.
answered Nov 23 '18 at 8:32
WolfalooWolfaloo
7211
7211
I can use the data in the cells to determine if OK or NOT OK, kinda the if the value in this range or the value in this range is not "missing" then it is OK, but seems I'm struggling to manage to get the "if any of the cells in the range is not A" part. I want to avoid VBA because basically I'm not good in VBA, and maybe it will generate even more questions (I know my weakness)
– Lohengrin Perez
Nov 23 '18 at 8:39
If you need all the cells in an area to be "ok" you can use multiple conditions tied by AND with the different cells. If you need at least one cell in the area to be "ok" you can use OR instead, or any other combination of logic that will suit your needs
– Wolfaloo
Nov 23 '18 at 8:42
That one sounds more closer to what I want. Thanks for taking your time answering me, appreciate it.
– Lohengrin Perez
Nov 23 '18 at 8:47
No worries, in case this is not enough edit the question with your newfound issues and perhaps an example of your code
– Wolfaloo
Nov 23 '18 at 8:56
1
Sorry, my first question here (totally newbie). Done.
– Lohengrin Perez
Nov 23 '18 at 11:27
|
show 2 more comments
I can use the data in the cells to determine if OK or NOT OK, kinda the if the value in this range or the value in this range is not "missing" then it is OK, but seems I'm struggling to manage to get the "if any of the cells in the range is not A" part. I want to avoid VBA because basically I'm not good in VBA, and maybe it will generate even more questions (I know my weakness)
– Lohengrin Perez
Nov 23 '18 at 8:39
If you need all the cells in an area to be "ok" you can use multiple conditions tied by AND with the different cells. If you need at least one cell in the area to be "ok" you can use OR instead, or any other combination of logic that will suit your needs
– Wolfaloo
Nov 23 '18 at 8:42
That one sounds more closer to what I want. Thanks for taking your time answering me, appreciate it.
– Lohengrin Perez
Nov 23 '18 at 8:47
No worries, in case this is not enough edit the question with your newfound issues and perhaps an example of your code
– Wolfaloo
Nov 23 '18 at 8:56
1
Sorry, my first question here (totally newbie). Done.
– Lohengrin Perez
Nov 23 '18 at 11:27
I can use the data in the cells to determine if OK or NOT OK, kinda the if the value in this range or the value in this range is not "missing" then it is OK, but seems I'm struggling to manage to get the "if any of the cells in the range is not A" part. I want to avoid VBA because basically I'm not good in VBA, and maybe it will generate even more questions (I know my weakness)
– Lohengrin Perez
Nov 23 '18 at 8:39
I can use the data in the cells to determine if OK or NOT OK, kinda the if the value in this range or the value in this range is not "missing" then it is OK, but seems I'm struggling to manage to get the "if any of the cells in the range is not A" part. I want to avoid VBA because basically I'm not good in VBA, and maybe it will generate even more questions (I know my weakness)
– Lohengrin Perez
Nov 23 '18 at 8:39
If you need all the cells in an area to be "ok" you can use multiple conditions tied by AND with the different cells. If you need at least one cell in the area to be "ok" you can use OR instead, or any other combination of logic that will suit your needs
– Wolfaloo
Nov 23 '18 at 8:42
If you need all the cells in an area to be "ok" you can use multiple conditions tied by AND with the different cells. If you need at least one cell in the area to be "ok" you can use OR instead, or any other combination of logic that will suit your needs
– Wolfaloo
Nov 23 '18 at 8:42
That one sounds more closer to what I want. Thanks for taking your time answering me, appreciate it.
– Lohengrin Perez
Nov 23 '18 at 8:47
That one sounds more closer to what I want. Thanks for taking your time answering me, appreciate it.
– Lohengrin Perez
Nov 23 '18 at 8:47
No worries, in case this is not enough edit the question with your newfound issues and perhaps an example of your code
– Wolfaloo
Nov 23 '18 at 8:56
No worries, in case this is not enough edit the question with your newfound issues and perhaps an example of your code
– Wolfaloo
Nov 23 '18 at 8:56
1
1
Sorry, my first question here (totally newbie). Done.
– Lohengrin Perez
Nov 23 '18 at 11:27
Sorry, my first question here (totally newbie). Done.
– Lohengrin Perez
Nov 23 '18 at 11:27
|
show 2 more comments
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53442971%2fchanging-the-value-of-a-cell-in-excel-based-on-results-in-a-range%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
It sounds like it could be solved with a formula combined with conditional formatting but what have you tried?
– Wayne Phipps
Nov 23 '18 at 8:31
I have the impression that the colour is based on the value of the cells, and now you want to base yourself on the colour in order to do something. Wouldn't it be better to base yourself of the values too?
– Dominique
Nov 23 '18 at 9:06
@Wayne, I tried to use IF combined with OR and COUNTIF, using the values to modify OK or NOT OK..
– Lohengrin Perez
Nov 23 '18 at 13:04
@Dominique, Yep, I moved to that after, because I though maybe colours will be more simple to do.
– Lohengrin Perez
Nov 23 '18 at 13:04