• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Search results

  1. R

    Cannot see why code doesn't work - please help

    Dim test as String That's great, thanks for your help! Cheers, roe3p
  2. R

    Cannot see why code doesn't work - please help

    Excellent - then let's agree to agree! :) Your solution is certainly more elegant, but I'd suggest one amendment: Range("A1", Cells(Rows.count, 1).End(xlUp)) to define the range, rather than "A65536" - just in case the user is using Excel 2007+ and has more then 65536 rows of data. (without...
  3. R

    Cannot see why code doesn't work - please help

    Hi Smallman, I agree in general, but it can often be handy to have subs that only work on a targeted range (especially when working with sheets manually populated by someone else!) There may well be a better way to achieve what's needed in this case, but what Cricketnz has so far seems like...
  4. R

    Cannot see why code doesn't work - please help

    Hi Cricketnz, My bad, didn't test it - this should work though: UserRange.Offset(0, 4).Formula = "=IF(ISNUMBER(FIND(""" & StrSrch & """," & UserRange.Cells(1, 1).Address(False, False) & ")),""" & StrRepl & ""","""")" I changed a curly bracket to a normal one, removed the .Value from the end...
  5. R

    Cannot see why code doesn't work - please help

    Hi, The problem is that the output formula is missing all its quotes - so your final formula is reading: =IF(ISNUMBER(FIND(NON INVENTORY,B441)),STOCK, ) rather than: =IF(ISNUMBER(FIND("NON INVENTORY",B441)),"STOCK"," ") You just need to add double-double-quotes into your code as...
Back
Top