ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   traverse until non integer (https://www.excelbanter.com/excel-programming/354742-traverse-until-non-integer.html)

evil baby[_6_]

traverse until non integer
 

here is the problem I have. I'm trying to condition format a fe
different lines. As it stands now it will go across the spreadshee
until a zero value is found, however I would like it to keep goin
until it reaches a non integer value.

for example:

Jan Feb Mar Apr Jun Jul Aug Sep Oct Nov Dec YTD Calctype
25 50 21
96 cumulative


so I would like the macro to check all the values until it reaches th
word "cumulative

--
evil bab
-----------------------------------------------------------------------
evil baby's Profile: http://www.excelforum.com/member.php...fo&userid=3198
View this thread: http://www.excelforum.com/showthread.php?threadid=51784


Tom Ogilvy

traverse until non integer
 
rw = 1 ' set to row you want to traverse
i = 1
do while lcase(cells(rw,i) < "cumulative"


i = i + 1
Loop


another possibility

set rng = cells(rw,"IV").End(xltoLeft)
lastcol = rng.column

--
Regards,
Tom Ogilvy




"evil baby" wrote
in message ...

here is the problem I have. I'm trying to condition format a few
different lines. As it stands now it will go across the spreadsheet
until a zero value is found, however I would like it to keep going
until it reaches a non integer value.

for example:

Jan Feb Mar Apr Jun Jul Aug Sep Oct Nov Dec YTD Calctype
25 50 21
96 cumulative


so I would like the macro to check all the values until it reaches the
word "cumulative"


--
evil baby
------------------------------------------------------------------------
evil baby's Profile:

http://www.excelforum.com/member.php...o&userid=31983
View this thread: http://www.excelforum.com/showthread...hreadid=517844





All times are GMT +1. The time now is 12:26 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com