Could you tell me the vba code to copy a document from excel and paste it
into a new word document?
many thanks.
Could you tell me the vba code to copy a document from excel and paste it
into a new word document?
many thanks.
Hello Kevin
One way could be to record a macro in word while doing the import by hand.
then go to tools|macro|visualbasiceditor and there you find newmacros from
normal|modules that contains recorded macrocodes.
Here is example code I recorded while importing an excel document to word
Selection.InlineShapes.AddOLEObject ClassType:="Excel.Sheet.8", FileName:= _
"pathtodocument\documentname.xls", _
LinkToFile:=False, DisplayAsIcon:=False
hope this helps
..nippetee
"kevin" kirjoitti:
> Could you tell me the vba code to copy a document from excel and paste it
> into a new word document?
>
> many thanks.
Kevin, do you want to 'copy a form' (as in your subject line) or 'copy a
document (as in your message)?
To 'copy a form', in Excel, export the form to a file (File + Export file)
and import that file in Word (File + Import File)
"kevin" wrote:
> Could you tell me the vba code to copy a document from excel and paste it
> into a new word document?
>
> many thanks.
Hi,
Sorry I didn't explain myself clearly. I want the user to activate a button
which will copy a cell range from excel and paste it into a word document ?
Can you help.
"AA2e72E" wrote:
> Kevin, do you want to 'copy a form' (as in your subject line) or 'copy a
> document (as in your message)?
>
> To 'copy a form', in Excel, export the form to a file (File + Export file)
> and import that file in Word (File + Import File)
>
> "kevin" wrote:
>
> > Could you tell me the vba code to copy a document from excel and paste it
> > into a new word document?
> >
> > many thanks.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks