If Condition Macro Code

Status
Not open for further replies.

lakshmipathi123

Board Regular
Joined
Jul 10, 2012
Messages
52
Office Version
  1. 365
Platform
  1. Windows
Hi Experts,

I have query regarding If condition macro. Will you please prepare and get me the macro code

Here is an example

1. Find and Copy
Condition 1
If 20310-0000 is available
Copy all data related to 20310-0000 and paste into Sheet2
Else
Msg box No data
Condition 2
If 20320-0000 is available
Copy all data related to 20320-0000 and paste into Sheet3
Else
Msg box No data
And so on….

2. Find and Delete

Condition 1
If 20310-0000 is available
Delete all data related to 20310-0000
Else
Msg box No data
Condition 2
If 20320-0000 is available
Delete all data related to 20320-0000
Else
Msg box No data
And so on….

Thank you,
Lakshmipathi Y
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.
Status
Not open for further replies.

Forum statistics

Threads
1,223,228
Messages
6,170,875
Members
452,363
Latest member
merico17

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top