Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi ALl,
I am trying to create a macro to export to excel into a template but need to paste special. However nothing I try is working.
Please help
I have tried and only the first works but does not give me what I need
objExcelDoc.Sheets(sheetName).Paste
'objExcelDoc.Sheets(sheetName).PasteSpecial x1PasteValues
'objExcelDoc.Sheets(sheetName).PasteSpecial_Operation=xlPasteSpecialOperationAdd
'selectObj.Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _:=False, Transpose:=False
'selectObj.SpecialPaste
'objExcelDoc.Sheets(sheetName).("Paste Source Formatting")
I think your code is missing an activate- and/or select-statement before you try to paste your content.
- Marcus
Hi,
sub copy
ActiveDocument.GetSheetObject("TB08").CopyValuesToClipboard
end sub