Assuming that you want the numbering to skip if column contaibns "No", try
entering this into A1 and copying it down:-
=IF(B1<"No",ROW(B1)-COUNTIF($B$1:B1,"No"),"")
--
Alan Moseley IT Consultancy
http://www.amitc.co.uk
If I have solved your problem, please click Yes below. Thanks.
"Manos" wrote:
I have an excel where in column A i want to create an auto numbering.
In column B i have some codes and value No.
SO i want to count only the lines that have codes, an no the lines that have
value No.
A B
1 sub1
2 sub2
NO
3 sub3
thanks in advance for your prompt response
Manos