Word 2007 Short-Cut Question

W

WSR

I'd like to create a one key short-cut key that allows me to "Paste Special"
/ "Picture (Enhanced Metafile") since I use that feature a lot.

Any guidance/assistance is appreciated
 
P

PamC via OfficeKB.com

Record a macro and assign it to a shortcut key of your choosing.

PamC
 
W

WSR

My question regarding the macro is how do I make it "generic" so that it's
pasting what ever object I cut?

When I try to record the macro from a blank sheet, the paste button is
greyed out.

What I don't what the macro to do is Paste Special / Picture the same object
over and over again.

I want it to Paste Special the last object on the clipboard.

If this makes any sense.


Terry Farrell said:
Have you tested that method?
 
P

PamC via OfficeKB.com

Terry:

Yes, I have a such a macro, revised in 2004 or thereabouts, although I have
it assigned to a button not a shortcut. Here's the code

Sub Pastegraphic()
'
' Pastegraphic Macro
' Macro recorded 01/26/00
'

Selection.PasteSpecial Link:=False, DataType:=wdPasteMetafilePicture, _
Placement:=wdInLine, DisplayAsIcon:=False
Selection.Style = ActiveDocument.Styles("graphic")
End Sub

If you don't want to assign a style, comment out the line beginning
"Selection.Style".
The one I recorded for paste text is assigned to a shortcut. There is a
problem with recording certain actions in W2007. It will not record the
actions to delete tracked formatting changes, for example. (Yes, I know, no
longer as necessary.) But the recorded macro in an attached W2003 (dot.) add-
in runs just fine in W2007.

Regards,
PamC

Terry said:
Have you tested that method?
Record a macro and assign it to a shortcut key of your choosing.
[quoted text clipped - 5 lines]
 
P

PamC via OfficeKB.com

First copy an image. Then turn on the macro recorder, and go to it. You need
to record the steps for pasting an image that is already in memory (the
clipboard).

PamC
My question regarding the macro is how do I make it "generic" so that it's
pasting what ever object I cut?

When I try to record the macro from a blank sheet, the paste button is
greyed out.

What I don't what the macro to do is Paste Special / Picture the same object
over and over again.

I want it to Paste Special the last object on the clipboard.

If this makes any sense.
Have you tested that method?
[quoted text clipped - 7 lines]
 
P

PamC via OfficeKB.com

I meant _accept_ track formatting changes.

PamC wrote:
It will not record the
 
W

WSR

What I want to do is cut from another application and paste special as a
picture (enhanced metafile) format.

When I record the macro as you describe, the cut some cells from an Excel
file the result in the Word file is a table, not a picture.

Any ideas with my macro?

Here's the VB

Sub PasteSpecialPicture()
'
' PasteSpecialPicture Macro
'
'
Selection.PasteSpecial (wdPasteEnhancedMetafile)
End Sub


Thanks 8^>


PamC via OfficeKB.com said:
First copy an image. Then turn on the macro recorder, and go to it. You
need
to record the steps for pasting an image that is already in memory (the
clipboard).

PamC
My question regarding the macro is how do I make it "generic" so that it's
pasting what ever object I cut?

When I try to record the macro from a blank sheet, the paste button is
greyed out.

What I don't what the macro to do is Paste Special / Picture the same
object
over and over again.

I want it to Paste Special the last object on the clipboard.

If this makes any sense.
Have you tested that method?
[quoted text clipped - 7 lines]
Any guidance/assistance is appreciated
 
P

PamC via OfficeKB.com

I'm a macro recorder, not a macro writer. I can read them well enough to
figure out what they do but that's about it. Does your macro work on Word
text? If not, perhaps you should record it again. I just tried mine on an
excel sheet (I'm using W2007 right now), and it worked. So you could try
using mine—taking out the style line if you don't want that.

PamC


What I want to do is cut from another application and paste special as a
picture (enhanced metafile) format.

When I record the macro as you describe, the cut some cells from an Excel
file the result in the Word file is a table, not a picture.

Any ideas with my macro?

Here's the VB

Sub PasteSpecialPicture()
'
' PasteSpecialPicture Macro
'
'
Selection.PasteSpecial (wdPasteEnhancedMetafile)
End Sub

Thanks 8^>
First copy an image. Then turn on the macro recorder, and go to it. You
need
[quoted text clipped - 22 lines]
 
H

Herb Tyson [MVP]

Try this line:

Selection.PasteSpecial DataType:=9

--
Herb Tyson MS MVP
Author of the Word 2007 Bible
Blog: http://word2007bible.herbtyson.com
Web: http://www.herbtyson.com


WSR said:
What I want to do is cut from another application and paste special as a
picture (enhanced metafile) format.

When I record the macro as you describe, the cut some cells from an Excel
file the result in the Word file is a table, not a picture.

Any ideas with my macro?

Here's the VB

Sub PasteSpecialPicture()
'
' PasteSpecialPicture Macro
'
'
Selection.PasteSpecial (wdPasteEnhancedMetafile)
End Sub


Thanks 8^>


PamC via OfficeKB.com said:
First copy an image. Then turn on the macro recorder, and go to it. You
need
to record the steps for pasting an image that is already in memory (the
clipboard).

PamC
My question regarding the macro is how do I make it "generic" so that
it's
pasting what ever object I cut?

When I try to record the macro from a blank sheet, the paste button is
greyed out.

What I don't what the macro to do is Paste Special / Picture the same
object
over and over again.

I want it to Paste Special the last object on the clipboard.

If this makes any sense.

Have you tested that method?

[quoted text clipped - 7 lines]

Any guidance/assistance is appreciated
 
W

WSR

Thanks Herb & PamC

Using the following VB allows me to Paste/Special/Picture (Enhanced
Metafile)


Sub PasteSpecialPicture()
'
' PasteSpecialPicture Macro
'
'
Selection.PasteSpecial DataType:=9
End Sub


Herb Tyson said:
Try this line:

Selection.PasteSpecial DataType:=9

--
Herb Tyson MS MVP
Author of the Word 2007 Bible
Blog: http://word2007bible.herbtyson.com
Web: http://www.herbtyson.com


WSR said:
What I want to do is cut from another application and paste special as a
picture (enhanced metafile) format.

When I record the macro as you describe, the cut some cells from an Excel
file the result in the Word file is a table, not a picture.

Any ideas with my macro?

Here's the VB

Sub PasteSpecialPicture()
'
' PasteSpecialPicture Macro
'
'
Selection.PasteSpecial (wdPasteEnhancedMetafile)
End Sub


Thanks 8^>


PamC via OfficeKB.com said:
First copy an image. Then turn on the macro recorder, and go to it. You
need
to record the steps for pasting an image that is already in memory (the
clipboard).

PamC

WSR wrote:
My question regarding the macro is how do I make it "generic" so that
it's
pasting what ever object I cut?

When I try to record the macro from a blank sheet, the paste button is
greyed out.

What I don't what the macro to do is Paste Special / Picture the same
object
over and over again.

I want it to Paste Special the last object on the clipboard.

If this makes any sense.

Have you tested that method?

[quoted text clipped - 7 lines]

Any guidance/assistance is appreciated
 
H

Herb Tyson [MVP]

I'm glad it worked. It took a bit of detective work to figure out, since the
macro recorder recorded paste special as PasteAndFormat, instead.

--
Herb Tyson MS MVP
Author of the Word 2007 Bible
Blog: http://word2007bible.herbtyson.com
Web: http://www.herbtyson.com


WSR said:
Thanks Herb & PamC

Using the following VB allows me to Paste/Special/Picture (Enhanced
Metafile)


Sub PasteSpecialPicture()
'
' PasteSpecialPicture Macro
'
'
Selection.PasteSpecial DataType:=9
End Sub


Herb Tyson said:
Try this line:

Selection.PasteSpecial DataType:=9

--
Herb Tyson MS MVP
Author of the Word 2007 Bible
Blog: http://word2007bible.herbtyson.com
Web: http://www.herbtyson.com


WSR said:
What I want to do is cut from another application and paste special as a
picture (enhanced metafile) format.

When I record the macro as you describe, the cut some cells from an
Excel file the result in the Word file is a table, not a picture.

Any ideas with my macro?

Here's the VB

Sub PasteSpecialPicture()
'
' PasteSpecialPicture Macro
'
'
Selection.PasteSpecial (wdPasteEnhancedMetafile)
End Sub


Thanks 8^>


First copy an image. Then turn on the macro recorder, and go to it.
You need
to record the steps for pasting an image that is already in memory (the
clipboard).

PamC

WSR wrote:
My question regarding the macro is how do I make it "generic" so that
it's
pasting what ever object I cut?

When I try to record the macro from a blank sheet, the paste button is
greyed out.

What I don't what the macro to do is Paste Special / Picture the same
object
over and over again.

I want it to Paste Special the last object on the clipboard.

If this makes any sense.

Have you tested that method?

[quoted text clipped - 7 lines]

Any guidance/assistance is appreciated
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top