Using IF to copy data between sheets Help please

Paulbo

New Member
Joined
Nov 6, 2002
Messages
1
Greetings All,

I've got a task for an assignment thats driving me crazy...

I've got a worksheet called Data & one called Male (in the same wookbook). The data sheets lists gender (as M or F) & values related to height and weight.

My task is : "Use an IF function to copy appropriate male data from the data worksheet to the male worksheet"

I've worked out how to get a M result or leave a blank if its female in the Gender column on sheet Male but cannot figure out how to transfer the data for the other characteristics.

My starting point is :
=IF(Data!$B2="M","M","")

Now what do I do? Do I need nested IF statements or can the value_if_true be made to include all value on that row from Data sheet?

Second question - the row range is 2:207 - do I just fill the formula down or can it all be done with one IF statement using 2:207 arguement (somehow)?

Thanks in advance for any help.
 

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.
There may be another way to solve your problem. Filter the data on the datasheet to show only male data. Then copy the data and select the relevant top left hand corner cell in the Data sheet, then Edit, Paste Special and paste links to copy over links to the Male data.
 
Upvote 0
Paulbo -

say your data is in Data C, D & E

in Male sheet - to replicate the data in C2

=IF(DATA!$B2="M",DATA!C2,"")

copy this formula across D & E and you will get the results from DATA!D2 & E2 if B2 (gender) is Male.

Inarbeth - love the photos of Wivenhoe...used to live on Parkwood Avenue (by the park)...got any of the Cricket Club or Broad Lane (FC)???
 
Upvote 0

Forum statistics

Threads
1,214,652
Messages
6,120,746
Members
448,989
Latest member
mariah3

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