How insert rows between two dates which is available like this 23-04-2023 & in next row mentioned 30-04-2023

Anonymous
2023-09-07T07:17:20+00:00

How insert rows between two dates which is available like this 23-04-2023 & in next row mentioned 30-04-2023

23-04-2023

30-04-2023

I want to insert the row date wise between two available dates & further dates automatically filled on inserted row

Microsoft 365 and Office | Excel | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments
{count} votes

4 answers

Sort by: Most helpful
  1. Anonymous
    2023-09-07T07:51:29+00:00

    Hey there, my name is Ajibola and I'm excited to help you out today!

    To insert rows between two dates and automatically fill in the dates in between, you can use Excel or similar spreadsheet software. Here's a step-by-step guide using Excel as an example:

    1. Open Excel: Launch Excel or your preferred spreadsheet software.
    2. Enter the Initial Dates: In the first column, enter your initial dates. For this example, enter "23-04-2023" in cell A1 and "30-04-2023" in cell A2. You should have something like this:
       A
       1  23-04-2023
       2  30-04-2023
    
    1. Select the Cells: Click and drag to select the cells in column A where you want to insert the additional dates. In this case, you can select cells A3 to A10 to insert dates for a week.
    2. Access the Fill Series Tool: Go to the "Home" tab in Excel's ribbon, and in the "Editing" group, you'll find a button called "Fill." Click on it, and a dropdown menu will appear. Select "Series."
    3. Configure the Series Options:
      • In the "Series in" field, make sure it says "Columns."
      • In the "Type" field, select "Date."
      • In the "Date unit" field, select "Day."
      • In the "Step value" field, you can leave it as "1."
    4. Set the Stop Value: In the "Stop value" field, enter the date where you want the series to stop. For this example, enter "30-04-2023."
    5. Click OK: After configuring the series options, click the "OK" button.
    6. Dates Filled In: Excel will automatically fill in the dates between the initial two dates you provided. You've successfully inserted rows with dates filled in between the initial two dates. Adjust the selection and series options as needed for your specific date range and the number of rows you want to insert.

    If you have any further questions or need additional assistance, please feel free to ask. I'm here to help!

    Give back to the Community. Help the next person who has this issue by indicating if this reply solved your problem. Click Yes or No below.

    Kind regards

    0 comments No comments
  2. Anonymous
    2023-09-07T14:35:04+00:00

    Hi,

    dates in activesheet in column A from row2...

    Image

    ===========================

    if you are not familiar with macros:

    step1

    Save  your Workbook with extension .xlsm (macros enabled workbook)

    Step2

    2a) press ALT+F11 to open Visual Basic

    2b) from the ribbon, select: Insert > Module and paste the code below on the right 

    2c) Press ALT+Q to Close Visual Basic

    ===========================

    [update-1]

    Sub Add_Rows() '<< START VBA

    Const sCol As String = "A" '<< dates in column A

    Const N As Long = 2 ' << 1st date in row 2

    Dim ws As Worksheet

    Set ws = ActiveSheet

    Dim LastR As Long, x As Long, t As Long, i As Long

    LastR = ws.Cells(Rows.Count, sCol).End(xlUp).Row

    Application.ScreenUpdating = False

    For i = LastR To N + 1 Step -1

    If ws.Cells(i, sCol).Value - Cells(i - 1, sCol).Value <> 1 And ws.Cells(i, sCol).Value > Cells(i - 1, sCol).Value Then

    t = ws.Cells(i, sCol).Value - ws.Cells(i - 1, sCol)

    x = 1

    Do

    ws.Cells(i, sCol).EntireRow.Insert

    ws.Cells(i, sCol).Value = ws.Cells(i + 1, sCol).Value - 1

    x = x + 1

    Loop Until x = t

    End If

    Next

    Application.ScreenUpdating = True

    End Sub '<< END VBA

    ====================

    Step3

    To run the macro, press ALT+F8, 

    select 'Add_Rows **'**from the list and click the run button.

    or

    add a button and assign the  vba macro

    ==============

    ==============

    NOTE!!

    dates

    a2<a3<a4 <a5

    sample

    0 comments No comments
  3. Ashish Mathur 101K Reputation points Volunteer Moderator
    2023-09-07T23:13:41+00:00

    Hi,

    In cell C2, enter this formula

    =SEQUENCE(A3-A2+1,,A2)

    Hope this helps.

    0 comments No comments
  4. Anonymous
    2023-09-08T00:21:08+00:00

    Excel 365 Pro Plus with Power Pivot and Power Query.

    With multiple dates, names and amounts.

    With dynamic Table, PivotTable and Slicers.

    No formulas, no VBA macro.

    https://www.mediafire.com/file_premium/5ub0kpvzy2g2b18/09_07_23.xlsx/file

    https://www.mediafire.com/file_premium/w1awyaor25ep3go/09_07_23.pdf/file

    0 comments No comments