Results 1 to 12 of 12

Thread: Building Word Documents based on Individual Excel Rows

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #5
    VBAX Expert
    Joined
    Aug 2004
    Posts
    818
    Location
    Quote Originally Posted by RonMcK
    Kenneth,

    Using his code would your suggestion change his code as follows?
    With tbl
        For i = ActiveCell.Row To ActiveCell.Row ' <<your change
            For j = 1 To 5
                .Cell(i, j) = wks.Cells(i, j)
            Next j
        Next i
    End With
    How do you get the command button to appear on the line the user selects?

    Thanks,
    How about this to get your button onto your active line?
    Private Sub Worksheet_SelectionChange(ByVal Target As Range)
        If Not Application.Intersect(Range("C:C"), Target) Is Nothing Then
            Sheet1.CommandButton1.Top = Target.Top
        End If
    End Sub
    Last edited by Aussiebear; 07-09-2025 at 03:07 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •