Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default needing some If Range value

Good afternoon ,
I'm lost . . .this bit of code is used in a 'call.' it works fine in the
body of the program, but does not work in any of my 'calls.' why??? I've
tried just about everything (except reboot). Still a rookie here, but I
can't seem to figure this out. Thanks in advance for any and all assistance.

For count = 3 To 1000
If Range("A" & count) = "Lanham" Then
If Range("H" & count) = "IX*" Then
figure = figure + 1
End If
End If
Next count
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default needing some If Range value

here's an example of the data the loop is 'counting' through:
A H
Lanham CK082917
Lanham CK082780
Lanham PT204185
Lawyer CK082960
Lawyer RB01MZW-060A
Lawyer RA01MZW-060A
Lawyer PT204673
Lawyer R01MRIC-060P




"Johnny Mick" wrote:

Good afternoon ,
I'm lost . . .this bit of code is used in a 'call.' it works fine in the
body of the program, but does not work in any of my 'calls.' why??? I've
tried just about everything (except reboot). Still a rookie here, but I
can't seem to figure this out. Thanks in advance for any and all assistance.

For count = 3 To 1000
If Range("A" & count) = "Lanham" Then
If Range("H" & count) = "IX*" Then
figure = figure + 1
End If
End If
Next count

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default needing some If Range value

I guess my trouble post was a little too vague. . . thanks anyway. . .I
figured it out. For some reason, I wasn't able to use '=' when comparing a
value with a wildcard. . .I ended up using 'Like' and it is working fine.

"Johnny Mick" wrote:

Good afternoon ,
I'm lost . . .this bit of code is used in a 'call.' it works fine in the
body of the program, but does not work in any of my 'calls.' why??? I've
tried just about everything (except reboot). Still a rookie here, but I
can't seem to figure this out. Thanks in advance for any and all assistance.

For count = 3 To 1000
If Range("A" & count) = "Lanham" Then
If Range("H" & count) = "IX*" Then
figure = figure + 1
End If
End If
Next count

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
needing rtd assistance JohnE Excel Discussion (Misc queries) 2 January 15th 08 10:28 PM
Needing Help Very Bad Mike Excel Worksheet Functions 6 July 19th 06 07:23 AM
Needing to know how to use a "and" in a formula.... Eric Excel Worksheet Functions 1 November 4th 04 06:47 PM
VBA newb needing help with an IF duster Excel Programming 4 June 27th 04 10:28 PM
Scenariao needing help with. convert range to string and back, Kevin G[_2_] Excel Programming 0 January 28th 04 03:23 PM


All times are GMT +1. The time now is 11:06 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"