Incrementing the numbers

Hmuna

New Member
Joined
Aug 18, 2011
Messages
7
Learning from your youtube number incrementing tutorial, i have a problem and hope you guys help me.

codeis.jpg
[/URL] Uploaded with ImageShack.us[/IMG]

I want to increment the number of the ID only if the CODE in "C Cell" is '1' (one), like in the picture. Before, i use "=ROWS(IF(A12>1,A$2:A12,A12))" but it only gives a continuous number, hope you can help me.

Thanks in advance
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
=IF(C3=1, A2+1, A2)

You'll manually input 150200001 into cell A2, then put the formula from A3 onwards.

If you don't want manual input for A2,

=IF(ISERROR(IF(C2=1, A1+1, A1)),150200001,IF(C2=1, A1+1, A1)).
 
Upvote 0
wow........thanks a lot.....you guys are awesome......hope i can do something for you. THANKS AGAIN....MAY GOD BLESS YOU ALL.
 
Upvote 0

Forum statistics

Threads
1,224,595
Messages
6,179,798
Members
452,943
Latest member
Newbie4296

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