Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9222681
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T03:53:24+00:00 2026-06-18T03:53:24+00:00

I want to merge a cell automatically with the one underneath if the cell

  • 0

I want to merge a cell automatically with the one underneath if the cell has a certain value ("vv").
a solution i found is to check every cell in an array every time a change is made, but thought there would be a possibility to check the value of a cell after it changed?

So if I enter in a blank cell "vv" (without quotes) and I select a different cell I’d like that cell (with vv in it) to merge with the one right under it.
in my solution with the array it takes a second every time you change a cell, which is not neat if you make a lot of changes.
Any help?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T03:53:25+00:00Added an answer on June 18, 2026 at 3:53 am

    Try this code in your worksheet:

    Private Sub Worksheet_Change(ByVal Target As Range)
        If Target.Value = "vv" Then Target.Resize(2).Merge
    End Sub
    

    In case you want to prevent any content in the cell below, this code will ask you if the cells shall be merged in case any content is found:

    Private Sub Worksheet_Change(ByVal Target As Range)
        If Target.Value = "vv" Then 
            If Target.Offset(1).Value  "" Then
                 If MsgBox("Do you want to overwrite the cell below (containing '" & _
                     Target.Offset(1) & "?", vbYesNo) = vbYes Then
                     Target.Resize(2).Merge
                End If
            Else
                Target.Resize(2).Merge
            End If
        End If
    End Sub
    

    Note: The code needs to go in the target sheet, not a new module, as it is an Event procedure:

    code placement

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to merge array which have same key to be one. Example $options
I want to merge all files, which have one or two digits at certain
I want to merge this queries into only one, to return 2 values (scount_atp
I want to merge one .NET DLL assembly and one C# Class Library project
I have to array and I want to merge this two array with a
I have 2 images and I want to merge them into one on my
Want to merge array( 2 => 'a' 3 => 'b' ); and array( 7
I want to merge more than one PDF to Single PDF. I am using
I just want to merge two ArrayLists and have the contents in one ArrayList.
Please see a demo here. http://jsfiddle.net/wgstudio/CqNfZ/2/ I want merge cell(0,0) and cell(1,0) in a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.