+ Reply to Thread
Results 1 to 1 of 1

VBA for using a check box to Regen that row and then uncheck (ready to rerun macro)

  1. #1
    Registered User
    Join Date
    10-15-2023
    Location
    Massachusetts
    MS-Off Ver
    365
    Posts
    1

    Arrow VBA for using a check box to Regen that row and then uncheck (ready to rerun macro)

    Hello All,

    I'm making myself a task list, in this list i will have repeating tasks. Once the task is done (and dated) it needs to be done again (think how the laundry is in an never ending loop of despair).
    I'm VERY new to VBA and despite a few days of google searching (which I, previous to this endeavor, thought I was great at google research) I cannot figure out a code that will accomplish the above.

    THUS Far I've been able to do accomplish this for regenerating the line item (On Home Sheet)....... (Command Center- Help.xlsm):

    Sub regenerate_Task()

    ' regenerate_Task Macro
    Rows("2:2").Select
    Selection.Copy
    Rows("2:2").Select
    Selection.Insert Shift:=xlDown
    Application.CutCopyMode = False

    End Sub


    AND This for getting it to generate a date done:.....

    Sub CheckBox_Date_Stamp1()
    Dim xChk As CheckBox
    Set xChk = Sheet2.CheckBoxes(Application.Caller)
    With xChk.TopLeftCell.Offset(, 7)
    If xChk.Value = xlOff Then
    .Value = ""
    Else
    .Value = Date
    End If

    End With
    End Sub


    However I can't get the box to be pasted unchecked (so its ready to be used later) and I've not even added in the dating part that I've figured out on a different sheet (I had planned on combining the codes at the end). I've tried various things but ended up cutting them from the code above since I'd rather have a partly working code than a fully broken one.

    In a Perfect world I'd have the checkbox do the following things:

    Copy the line item
    Populate the date completed in a "Date Done" column (no preference what column this gets assigned to)
    Paste the task (the row we just checked) with an unchecked box to the last row (I know my code above just inserts below, i was also struggling with last row issues so i compromised)

    Any instruction, tips, tricks, full code for me to copy paste, etc. is welcome. TYSMIA
    Last edited by KCobster24; 10-15-2023 at 02:04 PM. Reason: added sheet name for clarity

+ 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. Check/uncheck one item will also check/uncheck subitems
    By 3po! in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 06-02-2022, 02:34 PM
  2. [SOLVED] Control check box check and uncheck macros
    By HINAUROOJ in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-08-2016, 04:04 PM
  3. [SOLVED] Uncheck Check Box 48 when Check Box 46 selected
    By JET2011 in forum Excel Programming / VBA / Macros
    Replies: 19
    Last Post: 02-26-2016, 12:58 PM
  4. Macro to automatically check or uncheck checkboxes based on a linked cell
    By lmshow in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-19-2013, 03:31 AM
  5. [SOLVED] multiple checkboxes macro check/uncheck
    By SHELTONUNDERDOG in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-07-2012, 01:36 PM
  6. [SOLVED] Formula/macro to check if jobs have successfully rerun
    By acmain in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 08-20-2012, 01:22 AM
  7. [SOLVED] How do I check/uncheck ten or odd Checkboxes by click on one check
    By Ken Vo in forum Excel General
    Replies: 5
    Last Post: 01-04-2006, 07:15 PM

Tags for this Thread

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