Results 1 to 5 of 5

Using evaluate using same style formula but different row number

Threaded View

  1. #1
    Forum Contributor
    Join Date
    08-14-2014
    Location
    US
    MS-Off Ver
    2013
    Posts
    135

    Using evaluate using same style formula but different row number

    I would like to use vba to do the calculation and input the value in column D

    So basically it works like this

    D2 has =IF(C2="","",C2-TODAY())
    D3 has =IF(C3="","",C3-TODAY())
    D4 has =IF(C4="","",C4-TODAY())
    I got as far as this
    Private Sub Worksheet_Change(ByVal Target As Range)
        If Not Intersect(Target, Columns(3)) Is Nothing Then
            If Target.Value <> "" Then
                Cells(Target.Row, "D").Value = Evaluate("=IF(ISBLANK($C" & Target.Row & "),"""",$C" & Target.Row & "-TODAY())")
            End If
        End If
    End Sub
    but if I use the fill handle to bring the dates down I get a mismatch error 13 on this line of code
    If Target.Value <> "" Then
    *** forgot to mention this is suppose to be a event change so if the value in C changes it updates D


    Thank you for looking
    Last edited by Mr_Bill; 09-24-2014 at 12:23 PM. Reason: *** Amended something

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Vba for row number of evaluate and max
    By stevow in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 04-20-2010, 08:59 AM
  2. Vba for row number of evaluate and max
    By stevow in forum Access Programming / VBA / Macros
    Replies: 0
    Last Post: 04-20-2010, 06:14 AM
  3. [SOLVED] How to evaluate a 'dotted' number using formulae (not UDF)
    By Alan in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 04-13-2006, 02:25 PM
  4. evaluate data by week number
    By in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 09-06-2005, 06:05 AM
  5. [SOLVED] evaluate data by week number
    By Steve G in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 09-05-2005, 11:05 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1