LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
Pat Pat is offline
external usenet poster
 
Posts: 122
Default Find 'Product not found'

Is there a way to find a cell(s) that causes an error when code is run. The
following code returns 'Product not found: 0' error. I have looked up and
down but cannot find the offending 3 cells.


For Each Target In rng1
sProd = Target.Parent.Cells(Target.Row, 18)

res = Application.Match(sProd, _
Worksheets("ControlCentre").Range("C77:C1000"), 0)
If Not IsError(res) Then
With Worksheets("ControlCentre")
' Will return quantity 'Back into stock'
If IsNumeric(Target.Value) Then
Set rng2 = .Cells(res + 76, icol)
rng2.Value = rng2.Value + Target.Value
End If
End With
Else
MsgBox "Product Not found: " & sProd
End If
Next


 
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
How Can Find Product Key ! Tufail Excel Discussion (Misc queries) 6 September 18th 09 05:22 PM
Find the next date for a product Algeraist Excel Discussion (Misc queries) 8 November 20th 08 05:31 PM
Formula to lookup product name and add qty's of all that are found Soulscream Excel Worksheet Functions 1 June 13th 08 09:49 PM
Error 1706. No valid source could be found for the product Microso Wiley C Excel Discussion (Misc queries) 0 August 8th 05 10:41 AM
Identify product not found Pat Excel Programming 1 December 6th 04 08:55 PM


All times are GMT +1. The time now is 03:30 PM.

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"