Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
copying between office apps ( excel & Word )
I've done a little programing in Word & Excel VBA and am
trying to open a word doc, select some text Copy to clipboard , then write to Excel feild or Copy from Excel to Word in the same way. I normaly find code by creating a macro the examining the results an looking up things i don't understand in the help. but the macro dose not work when you switch apps. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
copying between office apps ( excel & Word )
Hi phil,
You can use the following to do what you want. Add this macro to a module and then select some text. Then just run the macro Sub copytoexcel() Selection.Copy Set xl = CreateObject("Excel.application") xl.Workbooks.Add xl.Range("a1").Select xl.ActiveSheet.Paste xl.Application.Visible = True Set xl = Nothing End Sub Phil wrote: *I've done a little programing in Word & Excel VBA and am trying to open a word doc, select some text Copy to clipboard , then write to Excel feild or Copy from Excel to Word in the same way. I normaly find code by creating a macro the examining the results an looking up things i don't understand in the help. but the macro dose not work when you switch apps. * --- Message posted from http://www.ExcelForum.com/ |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
copying between office apps ( excel & Word )
Thanks I'll Give that a go
Phil -----Original Message----- Hi phil, You can use the following to do what you want. Add this macro to a module and then select some text. Then just run the macro Sub copytoexcel() Selection.Copy Set xl = CreateObject("Excel.application") xl.Workbooks.Add xl.Range("a1").Select xl.ActiveSheet.Paste xl.Application.Visible = True Set xl = Nothing End Sub Phil wrote: *I've done a little programing in Word & Excel VBA and am trying to open a word doc, select some text Copy to clipboard , then write to Excel feild or Copy from Excel to Word in the same way. I normaly find code by creating a macro the examining the results an looking up things i don't understand in the help. but the macro dose not work when you switch apps. * --- Message posted from http://www.ExcelForum.com/ . |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Very slow using SaveAs in Excel (and other Office apps) | Excel Discussion (Misc queries) | |||
Error message when copying Excel Pie Chart to Word (in Office 2007 | Charts and Charting in Excel | |||
Office app icons not associated with apps vista upgrade, office 20 | Setting up and Configuration of Excel | |||
Adobe Acrobat isn't available in office apps! | Excel Discussion (Misc queries) | |||
Office Apps accessing the Internet | Excel Discussion (Misc queries) |