![]() Selection.PasteSpecial Paste:=xlPasteValues If Application.ClipboardFormats(1) -1 Then In Excel open visual basic (Alt+F11) and paste this code into one of the PERSONAL.XLS modules: To map your new macro to a keyboard combination in Word 2007 do these simple 10 (Ten!) steps: 01 Click Office ButtonĠ5 Pick Macros in Categories drop-down listĠ6 Select your new macro in Macros drop down listĠ7 Position your cursor into Press new shortcut key ![]() I recommend to map this macro to Alt+V key combination. Who can suggest a better way of doing this without using dreaded “ GoTo” statements? It works multiple times, so you can paste the same string over and over again. It works in all Word versions, including Office 2010. First statement (Selection.PasteSpecial) handles rich text formats, and second statement (Selection.PasteAndFormat) deals with pasting Unicode strings. This macro was tested with Word 2007, and it can handle paste from Web and from Visuals Studio. Selection.PasteAndFormat (wdFormatPlainText) ![]() Placement:=wdInLine, DisplayAsIcon:=False Selection.PasteSpecial Link:=False, DataType:=wdPasteText, _ As of WED, I adopted this little macro as final version: Sub PasteText() Over the course of the day this is a huge inefficiency. Normally, you would do this with Paste Special, but this is several awkward clicks and many seconds lost.
0 Comments
Leave a Reply. |