Hi,
I am trying to let Excel save active workbook just before my paste as values code, however I can't figure a way to store the clipboard before the Activeworkbook.Save event, and after the event the clipboard is lost if it is consist of data from another or current excel sheet. It is no problem to do the Save and paste code if the Copy is from another application, ie. Outlook.
Any ideas?
Brgds
Thomas
I am trying to let Excel save active workbook just before my paste as values code, however I can't figure a way to store the clipboard before the Activeworkbook.Save event, and after the event the clipboard is lost if it is consist of data from another or current excel sheet. It is no problem to do the Save and paste code if the Copy is from another application, ie. Outlook.
Any ideas?
Code:
Sub PasteasValue()
Application.EnableEvents = False
Application.ScreenUpdating = False
ActiveWorkbook.Save
Selection.PasteSpecial Paste:=xlPasteValues
Application.EnableEvents = True
Application.ScreenUpdating = True
End Sub
Brgds
Thomas