+ Reply to Thread
Results 1 to 3 of 3

Copy changing value to next cell

  1. #1
    Registered User
    Join Date
    06-22-2022
    Location
    South Africa
    MS-Off Ver
    16.62
    Posts
    3

    Copy changing value to next cell

    Here I have a excel "Lunchbox" Configurator. (I have attached a sample workbook and a screenshot)

    To create a lunchbox you must choose 1 main, 1 side, 1 sweet. There are 3 availabe options for every main, side and sweet.

    You can create a lunchbox configuration by selecting options from the dropdown list which will then display next to "Lunchbox combo".

    I want to create a button that saves a configuration when the "save" button is pressed. This will place the luncbox combo next to day one. When a new configuration is created and the save button is pressed, it wil copy the text next to day 2. Creating a 3rd configuation a saving it will place it next to day 3 and so on.

    I am only know starting to learn vba so any help or solutions will greatly be appreciated! Many thanks

    Regards
    Attached Images Attached Images
    Attached Files Attached Files
    Last edited by AliGW; 06-23-2022 at 05:27 AM. Reason: Irrelevant section of title removed.

  2. #2
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    8,382

    Re: Copy changing value to next cell

    OK. Try.
    HTML Code: 
    Option Explicit
    Sub lunch()
    Dim lr&
        lr = IIf(IsEmpty(Range("G8")), 7, Cells(15, "G").End(xlUp).Row)
        If lr = 14 Then
            MsgBox "Full!"
            Exit Sub
        End If
        Range("G" & lr + 1).Value = Range("G6").Value
    End Sub
    Right click on button, assign the code to.
    Attached Files Attached Files

  3. #3
    Registered User
    Join Date
    06-22-2022
    Location
    South Africa
    MS-Off Ver
    16.62
    Posts
    3

    Re: Copy changing value to next cell

    Thank you )

+ 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: 08-31-2019, 01:03 PM
  2. [SOLVED] Lowest average of student and return student name
    By johnsnider1 in forum Excel General
    Replies: 8
    Last Post: 08-25-2018, 08:48 AM
  3. Select and copy the record based on student age
    By malarvel in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-08-2016, 12:07 PM
  4. [SOLVED] copy and paste student master data
    By Excel_Pa in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-24-2016, 03:56 AM
  5. [SOLVED] VBA for copy, paste student master data
    By Excel_Pa in forum Excel General
    Replies: 1
    Last Post: 03-10-2016, 11:09 AM
  6. Copy & paste from Particular Student details from different files into Onefile
    By KumarPK in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-13-2015, 10:03 AM
  7. Replies: 1
    Last Post: 02-06-2014, 08:07 AM

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