Comparing and copy cells VBA script
Closed
vimol
Posts
4
Registration date
Friday October 4, 2013
Status
Member
Last seen
October 7, 2013
-
Oct 4, 2013 at 09:59 AM
Blocked Profile - Oct 7, 2013 at 02:43 PM
Blocked Profile - Oct 7, 2013 at 02:43 PM
Related:
- Comparing and copy cells VBA script
- Vba case like - Guide
- Number to words in excel formula without vba - Guide
- Vba create folder if not exist ✓ - Excel Forum
- Vba check if value is in array - Guide
- Anu script manager 7.0 free download filehippo - Windows 7 Forum
2 responses
Good Morning.
The logic for If statements in excel is as follows:
=if(logic test, true, false)
So, with that in mind, if your data starts with:
A1 B1
"apple" "apple"
In cell C1, you could have the formula of:
=if(A1=B1,"There are both apples","they do not match")
Now, that we have the first logic statement, we can nest other logical tests in the first If statement for:
=If(A1=B1,IF(someothervalue=sometest,"the first test was true, and so was the scond test","the first test was true, but the second test is false"),"Failed the first test because they do not match")
Let me know if that gets you further. We will tackle to second part of your solution after you understand the logic tests.
I understand you are looking for VBA code, this is in formula bar n the sheet itself, and does not require a module.
Please post back.
//ark
-Contributor
The logic for If statements in excel is as follows:
=if(logic test, true, false)
So, with that in mind, if your data starts with:
A1 B1
"apple" "apple"
In cell C1, you could have the formula of:
=if(A1=B1,"There are both apples","they do not match")
Now, that we have the first logic statement, we can nest other logical tests in the first If statement for:
=If(A1=B1,IF(someothervalue=sometest,"the first test was true, and so was the scond test","the first test was true, but the second test is false"),"Failed the first test because they do not match")
Let me know if that gets you further. We will tackle to second part of your solution after you understand the logic tests.
I understand you are looking for VBA code, this is in formula bar n the sheet itself, and does not require a module.
Please post back.
//ark
-Contributor
vimol
Posts
4
Registration date
Friday October 4, 2013
Status
Member
Last seen
October 7, 2013
Oct 5, 2013 at 05:09 AM
Oct 5, 2013 at 05:09 AM
Thank you for answer!
But what I need is: In A1 is XYZ in B1 is nothing so take the information XYZ and copy to Sheet2(or another column). If in B1 is something written (mustn't match with A1!) do nothing.
But what I need is: In A1 is XYZ in B1 is nothing so take the information XYZ and copy to Sheet2(or another column). If in B1 is something written (mustn't match with A1!) do nothing.
vimol
Posts
4
Registration date
Friday October 4, 2013
Status
Member
Last seen
October 7, 2013
Oct 5, 2013 at 09:17 AM
Oct 5, 2013 at 09:17 AM
Yes I did.
Alright, now apply comething like this...
https://ccm.net/faq/25499-a-vba-code-to-conditionally-copy-data-from-one-sheet-to-another#q=formula+to+copy+cell+to+another+sheet+in+excel&cur=1&url=%2F
It is out there!
https://ccm.net/faq/25499-a-vba-code-to-conditionally-copy-data-from-one-sheet-to-another#q=formula+to+copy+cell+to+another+sheet+in+excel&cur=1&url=%2F
It is out there!
vimol
Posts
4
Registration date
Friday October 4, 2013
Status
Member
Last seen
October 7, 2013
Oct 7, 2013 at 10:00 AM
Oct 7, 2013 at 10:00 AM
Thank you but I don't see how this script can resolve my problem. I don't see there any comparing betwen cells or something. I don't see there even one time If mentioned... Maybe I'm stupid can you please explain me how can I use that?
My point was to combine the two, and let us know what you need help with. I am not here to PRODUCE A COMPLETE PRODUCT for YOU, I am here to provide you with help along the way.
I would love to be able to ask the forum to produce my RANGED WEAPON COLLIDER for me. But I might ask how would I go about tracking who collided with what, because I was stuck ON THAT portion.
The reason that you do not see an IF statement in the second link, is because IT WAS ASSUMED that you understood the IF THEN portion of your solution.
I will assist in certain logic hang ups, and methods and such, I will even go as far a wireframe a solution for you. I wil not wrieframe it, write the logic, and author the soltuion, What part are you going to do? What would you learn from that? Is this for work or school? If it is for school, then I am OUT!
Pleae post back with what you have come up with, and I , like most others here, will be happy to help.
Have a great day, and Have fun. Please post back!
I would love to be able to ask the forum to produce my RANGED WEAPON COLLIDER for me. But I might ask how would I go about tracking who collided with what, because I was stuck ON THAT portion.
The reason that you do not see an IF statement in the second link, is because IT WAS ASSUMED that you understood the IF THEN portion of your solution.
I will assist in certain logic hang ups, and methods and such, I will even go as far a wireframe a solution for you. I wil not wrieframe it, write the logic, and author the soltuion, What part are you going to do? What would you learn from that? Is this for work or school? If it is for school, then I am OUT!
Pleae post back with what you have come up with, and I , like most others here, will be happy to help.
Have a great day, and Have fun. Please post back!