+ Reply to Thread
Results 1 to 1 of 1

how to change value in one cell based on value in other cell?

  1. #1
    Registered User
    Join Date
    02-05-2019
    Location
    Bradford
    MS-Off Ver
    2016
    Posts
    15

    how to change value in one cell based on value in other cell?

    Hello Everyone,

    I want to write macro that will change one cell value to 0 when I will have "YES" in another cell. I found code that almost fits my purpose:

    Private Sub worksheet_change(ByVal target As Range)
    If Range("b3").Value = "DN" Then
    Range("C3:C5").Value = 0
    End If
    End Sub

    problem is that I want it to work not only in that one cell but on the cells below as well. Also I want it to change value to previous one if the value of that other cell will be "NO" or blank.

    Can you help? Anyone?

    Kind regards,
    Daniel
    Last edited by Danielnir; 04-22-2019 at 01:18 PM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 6
    Last Post: 01-23-2018, 04:49 AM
  2. [SOLVED] EXCEL NEWB.....Change cell color based on text in a cell on another sheet
    By anon1988 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-27-2014, 12:16 AM
  3. Macro to change colour of cell based on finding a specific word in the cell
    By Shelby761 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-24-2014, 09:46 AM
  4. Replies: 5
    Last Post: 12-07-2013, 02:21 PM
  5. Replies: 3
    Last Post: 11-08-2013, 03:10 PM
  6. Replies: 3
    Last Post: 12-16-2012, 12:49 PM
  7. Change cell values based on Active Cell Address in Excel 2007 with no VBA
    By bdmistri in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 08-07-2009, 02:01 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