View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
sugargenius sugargenius is offline
external usenet poster
 
Posts: 26
Default copy/paste column remove formulas

I need to copy a column and paste it special to remove formulas. The
columns position is variable.

here's what i've tried so far

*--remove formula for totals
IF lnTotalColumn 1
loXLSheet.Columns(lnTotalColumn).Copy
*!* loXLSheet.Range(Get_Col(lnTotalColumn)+
"1").PasteSpecial(xlPasteValues)
*!* loXLSheet.Columns(lnTotalColumn).PasteSpecial(xlPa steValues)
loXLSheet.Range(Get_Col(lnTotalColumn)+ "1").Select
loXLSheet.Application.Selection.PasteSpecial(xlPas teValues)
ENDIF


Most threw error:
OLE IDispatch exception code 0 from Microsoft Office Excel: This
operation requires the merged cells to be identically sized... (1429)

I'd rather not use selection.