LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Help needed on loop


Hello, I am struggling to find a solution to the following problem an
would really appreciate any help.

On Sheet1 I have a list of jobs numbers in column A, column B is th
customer, column C is the date, column D is the price, column E is th
invoice number.

I have a loop which looks though column B and basically says i
customer = "United" then put an invoice number in column E.

This works fine but at the same time this loop is running I would lik
it to populate the Invoice Sheet.

So, for example, it has verified that job number 1 is United so has pu
invoice number 100 in column D. It would then need to go into th
Invoice Sheet and put Job Number 1 in cell A1, the date for job 1 i
B1, the price for job 1 in C1.

The next time the loop goes round it would need to put the invoic
number in column D again but when it goes to the invoice sheet it wil
realise that there is already something in A1 so it will put it in A2.

The code for my loop is
--------------------------------
Sub InvoiceUnitedJobs()
Dim cell As Range
For Each cell In Worksheets("Sheet1").Range("B:B")
If cell.Value = "United" Then
cell.Offset(0, 3).Value = 1
Else
End If
Next
End Sub
-------------------------------

I know this explanation has been very long-winded but would appreciat
any guidance.
Thanks

John

--
johncassel
-----------------------------------------------------------------------
johncassell's Profile: http://www.excelforum.com/member.php...fo&userid=2501
View this thread: http://www.excelforum.com/showthread.php?threadid=54283

 
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
simple loop needed please Alan Excel Discussion (Misc queries) 1 May 5th 10 06:33 PM
Loop thru Range Help needed GregR Excel Programming 9 May 12th 06 10:12 PM
loop code needed JohnUK Excel Programming 1 June 14th 05 05:17 AM
Urgent Help needed on! Copy and Paste a Formula as Values using a Loop statement Edward S Excel Programming 4 June 26th 04 10:01 PM
help needed with timer / loop wendy_ia Excel Programming 0 June 17th 04 06:06 AM


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

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

About Us

"It's about Microsoft Excel"