The 'LinkedToExcel" is a required parameter for the PasteExcelTable method. This is the macro line I'm trying to convert from VB, as shown in my Word madro editor:

Selection.PasteExcelTable False, False, False

If I look up the PasteToExcel Method in Word help (I'm using Word2007) it shows the following parameters:

Pastes and formats a Microsoft Excel table.

Syntax

expression.PasteExcelTable(LinkedToExcel, WordFormatting, RTF)

expression Required. A variable that represents a Selection object.

Parameters

LinkedToExcel Required Boolean True links the pasted table to the original Excel file so that changes made to the Excel file are reflected in Microsoft Word.

WordFormatting Required Boolean True formats the table using the formatting in the Word document. False formats the table according to the original Excel file.

RTF Required Boolean True pastes the Excel table using Rich Text Format (RTF). False pastes the Excel table as HTML.

Example

This example pastes an Excel table into the active document. The parameters specify that the pasted table is linked to the Excel file, retains the original Excel formatting, and is pasted as RTF. This example assumes that the Clipboard contains an Excel table.

Visual Basic for Applications Sub PasteExcelFormatted() Selection.PasteExcelTable _ LinkedToExcel:=True, _ WordFormatting:=False, _ RTF:=True End Sub

In reply to Re^2: Trying to use Win32::OLE PasteExcelTable method by aaronbaum2000
in thread Trying to use Win32::OLE PasteExcelTable method by aaronbaum2000

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.