+ Reply to Thread
Results 1 to 9 of 9

Edit Table within Word Document from Excel

Hybrid View

  1. #1
    Forum Guru
    Join Date
    07-25-2011
    Location
    Florida
    MS-Off Ver
    Excel 2003
    Posts
    9,653

    Re: Edit Table within Word Document from Excel

    Sub FnEditAndSaveWordDoc()
        
        Dim objCell As Object
        
        With CreateObject("Word.Application")
            With .Documents.Open("D:\Users\DMol\Desktop\Client\Clients" & "\" & Cells(2, 2) & "\" & Cells(2, 2) & "_2017 Proposal.docx")
                .Parent.Visible = True
                With .Tables(1)
                    For Each objCell In .Columns(1).Cells
                        If Left(objCell.Range.Text, 2) = "[[" Then objCell.Row.Delete
                    Next objCell
                End With
                .Save
            End With
        End With
    End Sub
    Surround your VBA code with CODE tags e.g.;
    [CODE]your VBA code here[/CODE]
    The # button in the forum editor will apply CODE tags around your selected text.

  2. #2
    Registered User
    Join Date
    08-23-2014
    Location
    Miami, USA
    MS-Off Ver
    365
    Posts
    69

    Re: Edit Table within Word Document from Excel

    Perfect AlphaFrog, thank you so much for your help.

+ 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. open, edit, and save a word document based on user response in excel 2010 VBA
    By cmccabe in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-19-2016, 03:13 PM
  2. Is it possible to delete a Table in a Word Document through an Excel VBA Macro?
    By buhnen in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-28-2016, 10:44 AM
  3. VBA - Create Word Document or Edit Document if exists
    By unstable81 in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 01-11-2013, 08:27 AM
  4. Locating table # in WORD document with Excel VBA
    By submariner18 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 12-19-2012, 03:23 AM
  5. [SOLVED] how can I turn a table in Word into an Excel Document?
    By AnnieLondon in forum Excel General
    Replies: 2
    Last Post: 01-17-2006, 01:30 PM
  6. How do I convert a word table into an excel document?
    By Aaron in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 12-22-2005, 11:10 AM
  7. [SOLVED] excel table in a page of a word document, horizontally
    By AC in forum Excel General
    Replies: 1
    Last Post: 05-16-2005, 05:06 AM

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